[Zope] Re: apache rewrite rules brake plone/zope

Sascha Welter zopelist at betabug.ch
Wed May 3 09:56:25 EDT 2006


(Wed, May 03, 2006 at 09:21:47AM -0400) zope-request at zope.org wrote/schrieb/egrapse:
> From: "David Bear" <dwbear75 at gmail.com>
> Subject: [Zope] apache rewrite rules brake plone/zope

> I have the following rewrite rules for apache. The intent is all urls that
> have http://myhost/z2 in them will be redirected/rewritten by apache to the
> zope instance running on local host.
> 
> RewriteRule ^/z2/(.*)
> http://127.0.0.1:9080/VirtualHostBase/http/%{HTTP_HOST}:80
> /VirtualHostRoot/$1 [L,P]

Please just go to http://betabug.ch/zope/witch and get a set of proper
rewrite rules for this simple case of "inside out hosting". Or read the
VHM documentation and learn the inside outs yourself :-)
To me it looks like you forgot the _vh_z2 part, but I stopped bothering
to debug rewrite rules, since the witch spits them out just fine.

> RewriteRule ^/z2dav/(.*)
> http://127.0.0.1:9081/VirtualHostBase/https/%{HTTP_HOST
> }:443/VirtualHostRoot/$1 [L,P]

Likely the same here.

> RewriteRule ^/login_form(.*) https://%{HTTP_HOST}/login_form$1 [NE,L]

This one has no connection, as it is a redirect.

> There is something that I've left out becuase any attempts to view the plone
> site through apache are 'messed up', ie the graphics, fonts, style sheets,
> etc, are not included in the web page. Only some of the content in rendered
> in the browser. However, when I open the url http://127.0.0.1:9080/ the zope
> and plone site all works.
> 
> any hints on a rule I've left out?

Links "back" to images and CSS failing are a common symptom of a
RewriteRule now being correct in respect to the work the VHM does.

Regards,

Sascha



More information about the Zope mailing list