Filippo Giunchedi has uploaded a new change for review. https://gerrit.wikimedia.org/r/309574
Change subject: thumbor: tune nginx next_upstream behaviour ...................................................................... thumbor: tune nginx next_upstream behaviour Bug: T139606 Change-Id: I20d2ec5175db926fe2349a3c35abb2cc87ee5b7e --- M modules/thumbor/templates/nginx.conf.erb 1 file changed, 5 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/74/309574/1 diff --git a/modules/thumbor/templates/nginx.conf.erb b/modules/thumbor/templates/nginx.conf.erb index 7780b16..2a7b6d9 100644 --- a/modules/thumbor/templates/nginx.conf.erb +++ b/modules/thumbor/templates/nginx.conf.erb @@ -1,9 +1,9 @@ upstream thumbor { least_conn; - <% @ports.each do |port| %> + <%- @ports.each do |port| -%> server 127.0.0.1:<%= port -%>; - <% end %> + <%- end -%> } server { @@ -14,6 +14,9 @@ location / { proxy_redirect off; proxy_buffering off; + # fallback to the next upstream at most once, and no longer than 30s + proxy_next_upstream_timeout 30; + proxy_next_upstream_tries 1; proxy_set_header Host $http_host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; -- To view, visit https://gerrit.wikimedia.org/r/309574 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I20d2ec5175db926fe2349a3c35abb2cc87ee5b7e Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Filippo Giunchedi <fgiunch...@wikimedia.org> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits