mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
nginx: Enable keepalive for communication between lbs and frontends.
(imported from commit a7c8d9dfefbb6e5d01c8050688d831787b31bbd4)
This commit is contained in:
@@ -2,5 +2,6 @@
|
||||
include /etc/nginx/zulip-include/proxy_longpolling;
|
||||
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
# This should override the Connection setting in zulip-include/proxy
|
||||
proxy_set_header Connection $connection_upgrade;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
proxy_http_version 1.1;
|
||||
# Clearing the Connection header is required for keepalives from the load balancer
|
||||
# http://nginx.org/en/docs/http/ngx_http_upstream_module.html#keepalive
|
||||
proxy_set_header Connection "";
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_next_upstream off;
|
||||
|
||||
@@ -1,9 +1,13 @@
|
||||
upstream staging {
|
||||
server staging.zulip.net:443;
|
||||
|
||||
keepalive 10000;
|
||||
}
|
||||
|
||||
upstream prod {
|
||||
server prod0.zulip.net:443;
|
||||
|
||||
keepalive 10000;
|
||||
}
|
||||
|
||||
server {
|
||||
|
||||
Reference in New Issue
Block a user