[Zope] Mixing VirtualHostMonster, ProxyPass and RewriteRules

Itai Tavor itai@optusnet.com.au
Mon, 5 Mar 2001 12:17:24 +1100


Hi,

I'm using ProxyPass and VirtualHostMonster to serve Zope with Apache, 
and I want to add the force-manage-on-https trick that was mentioned 
recently, as well as serve some static Apache content. My problem is 
that I need to use RewriteRules to achieve these things, and 
RewriteRules don't seem to work alongside ProxyPass. I guess I could 
replace the ProxyPass with rewriteRules for accessing the Zope 
server, but then I lose the transparent proxy. And that would be a 
shame.

My main server config is:

<VirtualHost _default_:80>
     RewriteEngine on
     RewriteLog logs/rewrite_log
     RewriteLogLevel 9

     RewriteRule ^/manual(.*) /manual/$1 [L]    # Access Apache's manual
     RewriteRule manage(.*)$ / [F]                     # Block access 
to management screens

     ProxyPass / http://localhost:8080/VirtualHostBase/http/10.0.1.20:80/
     ProxyPassReverse / http://localhost:8080/VirtualHostBase/http/10.0.1.20:80/
     ProxyPass /misc_ http://localhost:8080/misc_
     ProxyPass /p_ http://localhost:8080/p_
     ProxyVia on
</VirtualHost>

But the RewriteRules are being ignored. They work ok if I disable the 
ProxyPass directives.

Help?
--
Itai Tavor                      -- "Je sautille, donc je suis."    --
itai@optusnet.com.au            --               - Kermit the Frog --
--                                                                 --
-- "Every day, once a day, give yourself a present"  - Dale Cooper --