Given the following url:

domain.com/wiki/

I'd like apache to redirect all requests below that (so domain.com/wiki/*) to otherdomain.com:8080/. But the trick is I want the user to always see domain.com/wiki/. And the webapp on otherdomain thinks it's running at the root level, so has internal links to css and images and such that are like /css/style.css. Those urls need to be rewritten to /wiki/css/style.css.

The following config gets mostly there but is missing the /css & /images rewrite solution:

ProxyRequests Off
ProxyPass /wiki/ http://otherdomain.com:8080/
ProxyPassReverse /wiki/ http://otherdomain.com:8080/

Any and all help appreciated.

link|improve this question
feedback

1 Answer

up vote 1 down vote accepted

I think you need to use something like ProxyHTMLURLMap.
If I remember it correctly it would work like this:

ProxyHTMLURLMap http://domain.com/wiki/css http://otherdomain.com:8080/css [R]

link|improve this answer
This looks right, and here's a nice example of how to do what I'm looking for: apachetutor.org/admin/reverseproxies – evil_breeds Oct 19 '11 at 13:02
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.