It's ok?
upstream rest {
server s1;
server s2;
}
server {
listen 80;
server_name _;
root /usr/share/nginx/html;
proxy_connect_timeout 3s;
proxy_read_timeout 3s;
proxy_intercept_errors on;
proxy_next_upstream non_idempotent http_500;
proxy_next_upstream_timeout 3s;
location / {
error_page 302 307 500 502 504 = @redirect;
proxy_pass http://rest;
}
location @redirect {
proxy_pass http://rest;
}
}
_______________________________________________
nginx mailing list
nginx@nginx.org
https://mailman.nginx.org/mailman/listinfo/nginx