Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
mod_rewrite puzzle
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
eje211
Tux's lil' helper
Tux's lil' helper


Joined: 09 Sep 2004
Posts: 128
Location: London, UK

PostPosted: Thu May 28, 2009 12:24 pm    Post subject: mod_rewrite puzzle Reply with quote

Yes! I have a problem with mod_rewrite! It's not very original, I know, but it does bother me. Can anyone explain this:

I'm trying to install Zope. This is in .htaccess and works without a problem:
Code:
   RewriteRule ^(.*) \
      http://127.0.0.1:8080/VirtualHostBase/http/example.com:80/Plone/VirtualHostRoot/$1 [L,R]
But THIS gives me a "Bad Gateway" error:
Code:
   RewriteRule ^(.*) \
      http://127.0.0.1:8080/VirtualHostBase/http/example.com:80/Plone/VirtualHostRoot/$1 [L,P]
The difference is that the first one is a redirect and the second is a proxy.

The localhost:8080 page opens without a glitch. If I change the rewrite so that it goes as a proxy to Wikipedia, it works too.

Now, a small confession: I'm a Gentoo user, but this is not on Gentoo. It's a commercial host. I have no access to the config files of Apache nor to the log files, thus my using .htaccess.

But EVERYTHING works on its own: the proxy, the localhost page, Zope, everything. It just does not work when it's put together! Could it be something as silly as a timeout? What else? Does anyone have an idea?

Thanks.
Back to top
View user's profile Send private message
smerf
l33t
l33t


Joined: 06 Nov 2004
Posts: 778
Location: Polska

PostPosted: Sat Jun 13, 2009 4:35 pm    Post subject: Reply with quote

I'm using something like this (with https):
Code:
RewriteRule ^/plone/(.*) http://127.0.0.1:8100/VirtualHostBase/https/%{SERVER_NAME}:443/VirtualHostRoot/_vh_zope/plone/$1 [L,P]


[R]edirect works for you, [P]roxy does not... maybe the server has proxy support turned off?
_________________
Microsoft is not the answer, Microsoft is the question, the answer is no.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum