server port number in requests

2008-04-23 Thread John ORourke
Hi folks, I can't seem to find a way to retrieve the inbound port number during requests. I have a server listening on multiple ports, and need to know which one the request came in on. Here's the setup: apache config: Listen 127.0.0.1:81 Listen 127.0.0.1:82 NameVirtualHost *:*

Re: server port number in requests

2008-04-23 Thread André Warnier
John ORourke wrote: Hi folks, I can't seem to find a way to retrieve the inbound port number during requests. I have a server listening on multiple ports, and need to know which one the request came in on. Here's the setup: apache config: Listen 127.0.0.1:81 Listen 127.0.0.1:82

Re: server port number in requests

2008-04-23 Thread André Warnier
André Warnier wrote: John ORourke wrote: Hi folks, I can't seem to find a way to retrieve the inbound port number during requests. I have a server listening on multiple ports, and need to know which one the request came in on. Here's the setup: apache config: Listen 127.0.0.1:81

Re: server port number in requests

2008-04-23 Thread Clinton Gormley
Hi John The underlying reason for this is that I have a reverse proxy in front of it, which proxies HTTP and HTTPS requests. The back-end needs to create self-referencing URLs but cannot tell if it's HTTP or HTTPS, so I decided to direct HTTP to port 81 and HTTPS to port 82. I'd prefer

Re: server port number in requests

2008-04-23 Thread André Warnier
André Warnier wrote: André Warnier wrote: John ORourke wrote: Hi folks, I can't seem to find a way to retrieve the inbound port number during requests. I have a server listening on multiple ports, and need to know which one the request came in on. Here's the setup: apache config:

Re: server port number in requests

2008-04-23 Thread Torsten Foertsch
On Wed 23 Apr 2008, John ORourke wrote: The underlying reason for this is that I have a reverse proxy in front of it, which proxies HTTP and HTTPS requests.  The back-end needs to create self-referencing URLs but cannot tell if it's HTTP or HTTPS, so I decided to direct HTTP to port 81 and

Re: server port number in requests

2008-04-23 Thread John ORourke
Many, many thanks for the input everyone - naturally it turned out to be a case of RTFM but here's a summary of the simplest ways to do it. I've no idea how I missed these in the docs, though I am at the bang-head-on-wall stage of development. (I'm going on the assumption that the proxy may

Re: server port number in requests

2008-04-23 Thread Rhesa Rozendaal
John ORourke wrote: Hi folks, The underlying reason for this is that I have a reverse proxy in front of it, which proxies HTTP and HTTPS requests. The back-end needs to create self-referencing URLs but cannot tell if it's HTTP or HTTPS, so I decided to direct HTTP to port 81 and HTTPS to