You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Tony Heal <th...@pace2020.com> on 2007/01/29 21:20:25 UTC
[users@httpd] ProxyPass
I have configured several virtual hosts on my apache 1.3-33 system. Each host has several webs. What I would like to do
is simplify this a little. Here is what I have and this works fine
ProxyPass /web1 http://other-server/web1
ProxyPassReverse /web1 http:// other-server/web1
ProxyPass /web2 http://other-server/web2
ProxyPassReverse /web2http:// other-server/web2
ProxyPass /web3 http://other-server/web3
ProxyPassReverse /web3 http:// other-server/web3
What I would rather do if possible is for each virtual host use only 2 line something like this
ProxyPass /$1 http://other-server/$1
ProxyPassReverse /$1 http://other-server/$1
1. Is this possible?
2. If so how?
3. If not is there a better alternative for what I am currently doing.
Tony
RE: [users@httpd] ProxyPass
Posted by Chirouze Olivier <ol...@volvo.com>.
I think this simplification is true, but only if Tony doesn't have a
kind of "garbage collector" "forbidden" last rule.
I'm using similar config, but the last rule is always
RewriteRule "*" ... Forbidden ([F])
... Which makes it mandatory to list all the "/webx" rules before...
Or maybe something like:
ProxyPass /web([1-3]) http://other-server/web$1
About the proxypass reverse,
ProxyPassReverse / http://other-server/
Should be enough indeed...
Olivier
Olivier CHIROUZE
I&0 Infrastructure
Volvo Information Technology
> -----Original Message-----
> From: jslive@gmail.com [mailto:jslive@gmail.com] On Behalf Of
> Joshua Slive
> Sent: 29 January 2007 21:46
> To: users@httpd.apache.org; theal@pace2020.com
> Subject: Re: [users@httpd] ProxyPass
>
> On 1/29/07, Tony Heal <th...@pace2020.com> wrote:
>
> > What I would rather do if possible is for each virtual host
> use only 2 line
> > something like this
> >
> >
> >
> > ProxyPass /$1 http://other-server/$1
> >
> > ProxyPassReverse /$1 http://other-server/$1
>
> > Is this possible?
> > If so how?
> > If not is there a better alternative for what I am currently doing.
>
> Hmmm... How exactly is the target config supposed to differ from:
> ProxyPass / http://other-server/
> ProxyPassReverse / http://other-server/
>
> You can do fancy stuff with RewriteRule and the [P] flag, but it
> doesn't seem necessary in this case.
>
> Joshua.
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP
> Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] ProxyPass
Posted by Joshua Slive <jo...@slive.ca>.
On 1/29/07, Tony Heal <th...@pace2020.com> wrote:
> What I would rather do if possible is for each virtual host use only 2 line
> something like this
>
>
>
> ProxyPass /$1 http://other-server/$1
>
> ProxyPassReverse /$1 http://other-server/$1
> Is this possible?
> If so how?
> If not is there a better alternative for what I am currently doing.
Hmmm... How exactly is the target config supposed to differ from:
ProxyPass / http://other-server/
ProxyPassReverse / http://other-server/
You can do fancy stuff with RewriteRule and the [P] flag, but it
doesn't seem necessary in this case.
Joshua.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org