VirtualHostBase VHM keyword doesn't work.
Zope 2.9 says in the Virtual Host Monster About Tab: "For example, suppose Zope is running on port 8080 behind an Apache running on port 80. You place a Virtual Host Monster in the Zope root Folder, and use Apache to rewrite "/(.*)" to http://localhost:8080/VirtualHostBase/http/www.buystuff.com:80/buystuff.com/...." However, the following in my Apache 2.2 httpd file does not work: <VirtualHost *:80> RewriteEngine on DocumentRoot /var/www Servername goodbyeken.com RewriteRule /(.*) http://goodbyeken.com:8080/VirtualHostBase/http/www.goodbyeken.com:80/goodby... </VirtualHost> The above directive results in a Zope "resource not found" error. I have a Virtual Host Monster called myVHM in my Zope root directory. myVHM is able to do redirections that do not include the VirtualHostBase keyword. Why doesn't the VirtualHostBase keyword work?
are you loading the proxy modules? here is part of the http.config file that is working for me, however with that configuration all request are going to zope. Is there a way to have part of the requests going to zope and others being served by apache? ------ LoadModule proxy_module modules/mod_proxy.so LoadModule proxy_http_module modules/mod_proxy_http.so LoadModule rewrite_module modules/mod_rewrite.so ------ <VirtualHost *:80> ServerAlias someName ServerSignature On CustomLog myLog.log ErrorLog myError.log LogLevel warn <IfModule mod_rewrite.c> RewriteEngine On RewriteRule ^/(.*) \ http://localhost:8080/VirtualHostBase/http/%{SERVER_NAME}:80/myVHM/VirtualHostRoot/$1 [L,P] </IfModule> </VirtualHost> -----Original Message----- From: zope-bounces@zope.org on behalf of Mark, Jonathan (Integic) Sent: Tue 4/10/2007 9:23 PM To: zope@zope.org Subject: VirtualHostBase VHM keyword doesn't work. Zope 2.9 says in the Virtual Host Monster About Tab: "For example, suppose Zope is running on port 8080 behind an Apache running on port 80. You place a Virtual Host Monster in the Zope root Folder, and use Apache to rewrite "/(.*)" to http://localhost:8080/VirtualHostBase/http/www.buystuff.com:80/buystuff.com/...." However, the following in my Apache 2.2 httpd file does not work: <VirtualHost *:80> RewriteEngine on DocumentRoot /var/www Servername goodbyeken.com RewriteRule /(.*) http://goodbyeken.com:8080/VirtualHostBase/http/www.goodbyeken.com:80/goodby... </VirtualHost> The above directive results in a Zope "resource not found" error. I have a Virtual Host Monster called myVHM in my Zope root directory. myVHM is able to do redirections that do not include the VirtualHostBase keyword. Why doesn't the VirtualHostBase keyword work?
(Tue, Apr 10, 2007 at 09:34:02PM -0700) Dilley, Hara wrote/schrieb/egrapse:
are you loading the proxy modules?
here is part of the http.config file that is working for me, however with that configuration all request are going to zope. Is there a way to have part of the requests going to zope and others being served by apache?
Please read http://wiki.zope.org/zope2/ZopeAndApache and then **do not bother to make up your own rewrite rule** but instead go to http://betabug.ch/zope/witch to get your rewriterule. Maybe (only maybe) this applies to you too: http://betabug.ch/blogs/ch-athens/437 (depending on what you mean by "others going to apache"). If anything goes wrong, pay special attention to the section "Debugging, Common Pitfalls, Problems" in the ZopeAndApache page. Regards, Sascha
On Wed, Apr 11, 2007 at 12:23:14AM -0400, Mark, Jonathan (Integic) wrote:
Zope 2.9 says in the Virtual Host Monster About Tab: "For example, suppose Zope is running on port 8080 behind an Apache running on port 80. You place a Virtual Host Monster in the Zope root Folder, and use Apache to rewrite "/(.*)" to http://localhost:8080/VirtualHostBase/http/www.buystuff.com:80/buystuff.com/...."
However, the following in my Apache 2.2 httpd file does not work:
<VirtualHost *:80> RewriteEngine on DocumentRoot /var/www Servername goodbyeken.com RewriteRule /(.*) http://goodbyeken.com:8080/VirtualHostBase/http/www.goodbyeken.com:80/goodby... </VirtualHost>
The above directive results in a Zope "resource not found" error.
It would be useful if you could tell us WHAT resource is not found. Check your logs. Your zope access log is very useful when trying to configure rewrite rules; you can see exactly what path Apache request.
I have a Virtual Host Monster called myVHM in my Zope root directory. myVHM is able to do redirections that do not include the VirtualHostBase keyword. Why doesn't the VirtualHostBase keyword work?
It does. My first guess would be that you don't have a folder named "goodbyeken.com". -- Paul Winkler http://www.slinkp.com
You are missing the [P] in your rewrite rule. Please follow How-tos to the letter. ;-) Stefan On 11. Apr 2007, at 06:23, Mark, Jonathan (Integic) wrote:
<VirtualHost *:80> RewriteEngine on DocumentRoot /var/www Servername goodbyeken.com RewriteRule /(.*) http://goodbyeken.com:8080/VirtualHostBase/ http/www.goodbyeken.com:80/goodbyeken.com/VirtualHostRoot/$1 </VirtualHost>
-- It doesn't necessarily do it in chronological order, though. --Douglas Adams
participants (5)
-
Dilley, Hara -
Mark, Jonathan (Integic) -
Paul Winkler -
Sascha Welter -
Stefan H. Holek