[Catalyst] Anyone using ProxyPass?
Richard Jones
ra.jones at dpw.clara.co.uk
Tue Jul 3 11:24:34 GMT 2007
Bill Moseley wrote:
> moseley at bumby:~$ sudo netstat -ltp | grep '85 '
> tcp 0 0 localhost:10085 *:* LISTEN 30585/apache2
> tcp 0 0 *:85 *:* LISTEN 30577/apache2
>
> Then in my app auto() I added:
>
> warn join "\n",
> "request = " . $c->req->uri,
> $c->request->header( 'X-Forwarded-Host' ),
> $c->uri_for( '/foo' ),
> '';
>
> And I get:
>
> $ GET http://bumby:85/foo.html >/dev/null
>
> request = http://bumby:85/foo.html
> bumby:85
> http://bumby:85/foo
>
> So, that's correct.
>
> Throw in some warn statements in Catalyst::Engine::Apache.
OK, what I have discovered so far:
1) There is definitely no $c->request->header('X-Forwarded-Host')
2) $c->req->uri and $c->uri_for( '/foo' ) both clearly show port 81
(equivalent to your 10085)
2) In Catalyst::Engine::Apache::prepare_path, $host = the IP address of
the server (not localhost or 127.0.0.1), and $port = 81.
Perhaps mod_proxy on the front-end server is not working properly (or at
all)?
--
Richard Jones
More information about the Catalyst
mailing list