How to preserve all request headers in reverse proxy (mod_proxy)
am 17.12.2009 18:40:45 von Todd Volkert--0015175ccf7a9c73c5047af01fa9
Content-Type: text/plain; charset=ISO-8859-1
Hi all:
In httpd 2.2, is it possible to preserve all HTTP headers when using
mod_proxy to provide a reverse proxy?
Here's my desired setup: I'm running two domains on one server backed by one
Tomcat instance. I'm trying to run httpd as a reverse proxy to send
http://www.domain1.com/... to http://localhost:8080/domain1/... and
http://www.domain2.com/... to http://localhost:8080/domain2/... (with HTTPS
traffic going to port 8443). Starting to play with this, I've set up the
following config:
ProxyRequests Off
Order deny,allow
Allow from all
ProxyPass / http://localhost:8080/domain1/
ProxyPassReverse / http://localhost:8080/domain1/
However, the request headers are being lost in the process. I'd like to
keep them all in tact. Is there any way to accomplish this? The
"ProxyPreserveHost" works for the host header, but what about the rest?
Thanks for the help!
-T
--0015175ccf7a9c73c5047af01fa9
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Hi all:
In httpd 2.2, is it possible to preserve all HTTP headers wh=
en using mod_proxy to provide a reverse proxy?
Here's my desired=
setup: I'm running two domains on one server backed by one Tomcat inst=
ance.=A0 I'm trying to run httpd as a reverse proxy to send
http://www.domain1.com/.">http://www.domain1.com/... to
://localhost:8080/domain1/.">http://localhost:8080/domain1/... and
ref=3D"http://www.domain2.com/.">http://www.domain2.com/... to
=3D"http://localhost:8080/domain2/.">http://localhost:8080/d omain2/... =
(with HTTPS traffic going to port 8443). Starting to play with this,=
I've set up the following config:
ProxyRequests Off
<Proxy *>
=A0 Order deny,allow<=
br> =A0 Allow from all
</Proxy>
ProxyPass /
"http://localhost:8080/domain1/">http://localhost:8080/domai n1/
Prox=
yPassReverse / http://localhost:=
8080/domain1/
However, the request headers are being lost in the process.=A0 I'd =
like to keep them all in tact.=A0 Is there any way to accomplish this?=A0 T=
he "ProxyPreserveHost" works for the host header, but what about =
the rest?
Thanks for the help!
-T
--0015175ccf7a9c73c5047af01fa9--