Page 1 of 2

[SOLVED] Hosting a Webapp

Posted: Sun Jun 09, 2013 4:13 am
by Spency
Hi,

I have two questions regarding hosting webapps.

First one is: Well, I'm trying to make my media wiki app page accessible from the internet. I followed this guide https://wiki.amahi.org/index.php/Hosting_a_website and decided to use spency.yourhda.com as the server alias. When I try to access spency.yourhda.com it just redirects to the local url, which is not available on the internet. This works if I'm local, but on a different network it doesn't work. I've tried it several times.

The only thing from the trouble shooting I can relate to is
Q: I do not see the app I want when accessing myusername.yourhda.com
This may be because the corresponding virtualhost does not have the name you expect on it, or because another virtualhost already has it and happens to take over
... but this seems like an incredibly generalised-horoscopic question.

I also tried this guide https://wiki.amahi.org/index.php/Secure_App_Access but I had the same problem, and it messed up the layout of the app. I don't know what I'm doing wrong wrong.

Secondly: In the first link I mentioned, there are instructions for setting up multiple web apps for hosting using CNAMEs for a domain. Is it also possible to setup a redirect like spency.net/mediawiki as an external address?

Hope this isn't too much information.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 5:53 am
by Spency
I tried the CNAME method as well, but it still redirects to the local address.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 6:32 am
by bigfoot65
The username in username.yourhda.com has to be the name you gave the HDA on amahi.org. So when you log in, you should see a name and all the specifics about your HDA.

Is that the one you are using? If not, you might try that.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 6:54 am
by Spency
Yes that's the one I'm using. My dynamic DNS is spency.yourhda.com my nickname is spency.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 7:13 am
by bigfoot65
OK, good. The hosting of multiple web apps is not working that I am aware. You can host one app per port at the moment, but that's it. If you use the app, Amahi Web-Apps Proxy app, you might be able to do more.

The app you are trying to access is on port 80? I presume you forwarded the port on your router, correct?

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 8:08 am
by Spency
Yes, port 80 and 443 point to the HDA.

All I need really is to host one app, using a sub domain of my domain name.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 8:12 am
by bigfoot65
Sub domains are not supported in Amahi 6. They will be in 7, but you should be able to access the app via username.yourhda.com for both http and https.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 8:24 am
by Spency
Subdomain (subdomain.mydomain.net) works.
Yourhda (username.yourhda.com) works.
Local address (http://webapp) works.

My problem is: the server redirects to the local address (in this case http://mediawiki) regardless of the URL I put in. While this is fine for use on my home network, I cannot access mediawiki externally.

If I go via the dashboard (click on the mediawiki icon) does the same exact thing. For all apps.

If I go via web-apps proxy, I get a "The requested URL /mediawiki/ was not found on this server." For any app.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 8:27 am
by bigfoot65
Are you trying to access the external link while inside your network? If so, might try it from a device not connected to your network.

There may be something wrong with the dynamic DNS or maybe a firewall blocking access. Could be almost anything.

Re: Hosting a Webapp

Posted: Sun Jun 09, 2013 8:32 am
by bigfoot65
It also could be the port forward is not set up correctly on your router. I had one where it was called virtual host, on another port forward.