Welcome! Log In Create A New Profile

Advanced

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

October 18, 2010 05:46AM
On Mon, Oct 18, 2010 at 03:32:14AM -0400, DarkPepe wrote:

> Yes, I tryed that, but when using the external IP a weird error ocurrs.
>
> It's kind of difficult to explain, but the website shows some random
> content from any of the scripts hosted in that particular virtualhost
> instead of showing the appropiate info.
>
> Also other websites using different ips get mixed up with the website
> associated to that ip (EXTERNAL_IP_3)...
>
> For example:
>
> EXTERNAL_IP_1 is associated with www.websiteA.com but, when configuring
> the upstream with EXTERNAL_IP_3, www.websiteA.com displays the info (the
> bugged info) of www.example.com (wich is associated to EXTERNAL_IP_3).
>
> Probably that can be solved by using the correct IP for each virtualhost
> in proxy_pass (instead of http://apache) .. but eitherway, we still have
> the "bugged content" stuff there.

nginx can pass its address in HTTP header, you may try to use it on PHP side:

proxy_set_header X-Server-Address $server_address;


--
Igor Sysoev
http://sysoev.ru/en/

_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 17, 2010 04:12PM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

Jim Ohlstein October 17, 2010 04:58PM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 17, 2010 04:59PM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

Jim Ohlstein October 17, 2010 06:14PM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 18, 2010 12:28AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 18, 2010 12:30AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

Igor Sysoev October 18, 2010 02:26AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 18, 2010 03:16AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

Igor Sysoev October 18, 2010 03:24AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 18, 2010 03:32AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

Igor Sysoev October 18, 2010 05:46AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 18, 2010 12:04PM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

Igor Sysoev October 18, 2010 12:14PM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

DarkPepe October 18, 2010 12:25PM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

mtk April 30, 2011 06:01AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

mtk April 30, 2011 06:13AM

Re: Nginx Proxy + Apache and php5 as apache module SERVER_ADDR problem (HELP!)

Igor Sysoev October 18, 2010 03:22AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 163
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready