Saturday, July 24, 2004

Apache VirtualHost and Proxies

This is surprisingly easy to set up. There is some help here, but it doesn't deal with combining both proxy and virtualhost directives (as of this writing).
Here's my example set up:
<VirtualHost *:*>
ProxyPreserveHost On
ProxyPass /
ProxyPassReverse /

This can screw up if you're also doing proxy stuff to the same server outside of the VirtualHost block.