Rewrite or proxy_pass to internal ip ?

Francis Daly francis at daoine.org
Mon Oct 29 21:04:42 UTC 2012


On Mon, Oct 29, 2012 at 07:30:00AM -0400, hristoc wrote:
> Francis Daly Wrote:

Hi there,

> >   proxy_pass http://192.168.1.1:80/;

> one step forward but now I receive error 502 bad gateway. Server
> mydomain.com have 2 Ethernet. First one with realip that I connect, second
> one with virtual 192.168.1.2 connected to internal network. I don't want to
> add in my fw redirect rule, so I expect to do it over the web. When I access
> realip or domain name in that directory, I actually to see the web of my
> internal server located somewhere in local network.

I'm confused.

Which machine is creating these error messages?

If you start on the public nginx machine, and do

  curl -i -0 -H X-Real-IP:\ 10.1.2.3 http://192.168.1.1:80/

what response do you get? What response do you expect?

	f
-- 
Francis Daly        francis at daoine.org



More information about the nginx mailing list