server.com/index.php?r=iframe/index& .
server1.com/index.php?r=iframe/index&
server2.com/index.php?r=iframe/index&
..
upstream balancer {
server server1.com weight=20 max_conns=500 fail_timeout=5s;
server server2.com weight=20 max_conns=500 fail_timeout=5s;
...
}
location ~ /index.php?r=iframe/index\&$ {
proxy_pass http://balancer;
include proxy.inc;
proxy_set_header X-Forwarded-Proto $thescheme;
proxy_http_version 1.1;
proxy_set_header Connection "";
}
редиректило на стек серверов:
Так не работает: :(
location / {
mirror /mirror;
proxy_pass http://backend;
}
location /mirror {
internal;
proxy_pass http://test_backend$request_uri;
}