nginx not forwarding requests to backend servers.

Reinis Rozitis r at roze.lv
Wed Jul 27 15:42:11 UTC 2016


> Can anyone give me an example config of what it would look like in both 
> nginx.conf and default.conf using the names/info I have provided?

It seems you have taken the default configuration example but if you use 
nginx as a balancer without serving any .php (or other) files you actually 
don't need those *.php etc locations  - a single location / {} will do the 
job (means all requests go to backends).

For example:


http {
    upstream myappliationsite.net {
        ip_hash;
        server backendappsite1.net;
        server backendappsite2.net;
        server backendappsite3.net;
    }

server {
    listen       80;
    listen       443 ssl;

   server_name myappliationsite.net;

  location / {
     proxy_pass   http://myappliationsite.net;
     proxy_set_header HOST myappliationsite.net;
}
}




More information about the nginx mailing list