I have a Ruby on Rails website on Azure Linux (Ubuntu 14.04) that works perfectly from this address:
http://mydomain.cloudapp.net:3000
I want to get rid of the port in the address, and redirect it to a subdomain I have. I have set up the 000-default.conf
on Apache as per below:
<VirtualHost *:80>
ServerName myweb.example.com
DocumentRoot /var/www/html/mywebsite
ProxyPass / http://localhost:3000/
ProxyPassReverse / http://localhost:3000/
</VirtualHost>
I have restarted apache2. On my domain manager I have created a CNAME from myweb.example.com
to mydomain.cloudapp.net
.
However, when I enter http://myweb.example.com
I get 500 internal server error. It does work with http://myweb.example.com:3000
. What am I doing wrong?
EDIT: error_log info after trying to access http://myweb.example.com
[Sun Aug 23 16:02:40.634116 2015] [proxy:warn] [pid 3189:tid 140710588688128] [c
lient 92.251.128.56:52583] AH01144: No protocol handler was valid for the URL /.
If you are using a DSO version of mod_proxy, make sure the proxy submodules are
included in the configuration using LoadModule.