在此总结一些nginx常用配置,以防忘记。
1.nginx的proxy_next_upstream配置:
proxy_next_upstream error timeout http_500;
该配置用于下游服务出现500错误或者访问超时时,nginx响应502,然后会根据配置的upstream切换策略,切换到下一台后端服务器。
本条参考https://zhuanlan.zhihu.com/p/35803906。
来源:oschina
链接:https://my.oschina.net/u/4417652/blog/4725576