1

So here is my question - go easy and slow. I'm a GIS Consultant and general hack with linux. I inherited this volunteer job essentially because I knew more than the rest of the team - or the rest of the team isn't as stubborn as I am... With that said a number of people have been mucking around in the server before I got involved so I've been cleaning up a lot of things. The domain names have been changed to protect the innocent.

I have a server running Apache2 (port 80) and tomcat6 (8080) running on ubuntu server 10.4. There is a virtual host on Apache2 called "Runner" (the domain is runner.org). I have mod_proxy loaded.

I am trying to redirect everyone that visits runner.org to http://some.ip.address:8080/openrunner-webapp/

So far I've gotten runner.org assigned to the apache2 server. Someone set up a redirect in the httpd.conf file but I believe it needs to go into the virtualhost.

I tried setting the redirect in the virtualhost as: *ProxyPass / http://localhost:8080/openrunner-webapp

All that does is show me the root of the Apache webserver.

Anyway I'm stuck

Randal Hale
  • 111
  • 2
  • Are you trying to redirect (tell the client to ask a different URL for the content), or proxy (fetch the content directly from Apache and send it back to the client)? – Shane Madden Apr 08 '12 at 18:10

1 Answers1

2
<VirtualHost *:80>
  ServerName runner.org
  ServerAlias www.runner.org

  ProxyPass / http://some.other.ip:8080/openrunner-webapp     
  ProxyPassReverse / http://some.other.ip:8080/openrunner-webapp

  ErrorLog /var/log/apache2/runner.org_error.log
  CustomLog /var/log/apache2/runner.org_access.log combined
</VirtualHost>

Assuming that you want proxy (and not redirect) - that should do.

Piotr
  • 136
  • 2