Welcome! Log In Create A New Profile

Advanced

Re: nginx and cscart

Reinis Rozitis
June 27, 2011 05:10AM
Think of nginx as a transparent proxy/frontend - so instead of giving
proxy_set_header Host 192.168.1.1; you should set the real hostname of the
site proxy_set_header Host yoursite.com; (you can also use $host variable if
there are multiple/dynamic domains).

upstream mysites_hash {
ip_hash;
server 192.168.1.1;
server 192.168.1.2;
}

location /csupdate {
proxy_pass http://mysites_hash/csupdate;
proxy_set_header Host www.mydomain.com;
}

That way the backends/application should use full domain (the one you pass
in the header) in the redirects which will go through your nginx frontend
without the need of extra proxy_redirect directives.


rr


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

nginx and cscart

torajx June 25, 2011 03:29AM

Re: nginx and cscart

torajx June 27, 2011 01:04AM

Re: nginx and cscart

Reinis Rozitis June 27, 2011 05:10AM

Re: nginx and cscart

torajx June 27, 2011 05:54AM

Re: nginx and cscart

torajx June 27, 2011 05:56AM

Re: nginx and cscart

torajx July 02, 2011 02:32AM

Re: nginx and cscart

torajx July 02, 2011 02:41AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 256
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