Jump to content

Recommended Posts

Posted

We have Frog here, and we also have a domain which we want to run the site on. However, we don't want to dedicate the domain purely to it - we already do various reverse proxying things with it, pointing to various services in school (housepoints system, oliver library etc...). So what I want to do is reverse proxy http://domain/site to be the frog server, and then put a html redirect at the root of the site, leaving everything else intact.

 

However, Frog does various things by absolute paths - images stored in a user's area are under /user/blah, some system icons are in /sysicons and /sysimages etc... Meaning they are trying to access http://domain/user rather than http://domain/site/user.

 

Anyone got any ideas how I can overcome this? I've only ever done simple reverse proxying using 'ProxyPass /blah http://10.5.4.1/blah' and 'ProxyPassReverse /blah http://10.5.4.1/blah'.

Posted
we don't want to dedicate the domain purely to it

 

Could you give it a dedicated server - frog.yourdomain.com? That should be nice and simple to do, just an entry in your internal DNS to the local IP address and one in external DNS for your external IP address.

Posted

No, it has to go on our main domain, as it is becoming our main website. So, www.school.county.sch.uk will point to the homepage, via a redirect to /site which reverse proxies to the frog box.

 

It is already accessible via a sub-domain for frog use, but its the part where we're making it our main website too we're trying to do without having to reconfigure every other publicly visible site we have reverse proxied.

Posted
No, it has to go on our main domain, as it is becoming our main website.

 

Ah, I see. Don't you need Apache to do URL rewriting (mod_rewrite) rather than just plain reverse proxying?

Posted
Ah, I see. Don't you need Apache to do URL rewriting (mod_rewrite) rather than just plain reverse proxying?

 

I shouldn't really, no. But it looks like I will need to, yes, but then I'll also need a list of all the subdirectories too, to create all the different rules. It should simply be doing the whole kit and kaboodle with reverse proxying - like it does on all our other services.

 

Its all down to them using absolute paths for things that should be relative.

Posted
Be aware that this will break SSL.

 

Only if the SSL is being used on the Frog server... If it were being done on the Apache server instead, it'd be fine - we've encrypted services this way before.

 

The other way would be for the site not to use SSL at all, and the login to VLE be directed to the frog subdomain we have which has its own SSL set up.

Posted (edited)

Ok then, my back of a napkin apache config looks like this?

 

LoadModule proxy_module      modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule headers_module    modules/mod_headers.so
LoadFile   /usr/lib/libxml2.so
LoadModule proxy_html_module modules/mod_proxy_html.so
LoadModule xml2enc_module modules/mod_xml2enc.so

ProxyRequests off
ProxyPass /frog/ http://frog.internal.example.com/
ProxyHTMLURLMap http://frog.internal.example.com /frog


       ProxyPassReverse /
       ProxyHTMLEnable On
       ProxyHTMLURLMap  /      /frog/
       RequestHeader    unset  Accept-Encoding

 

For the purposes of the above configuration I've ignored the possibility of any caching/load balancing/etc.

Edited by Geoff

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...