From 45dd51e2616a417c20a49e08789aecc2882dfea4 Mon Sep 17 00:00:00 2001 From: Stepan Vladovskiy Date: Wed, 18 Oct 2023 08:00:04 -0300 Subject: [PATCH] feat: no buffer nginx --- nginx.conf.sigil | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/nginx.conf.sigil b/nginx.conf.sigil index 14d4666..2a299aa 100644 --- a/nginx.conf.sigil +++ b/nginx.conf.sigil @@ -48,14 +48,18 @@ server { location / { proxy_pass http://{{ $.APP }}-{{ $upstream_port }}; - {{ $proxy_settings }} - {{ $gzip_settings }} - proxy_buffering off; - proxy_cache off; - proxy_read_timeout 36000s; - {{ $cors_headers_options }} - {{ $cors_headers_post }} - {{ $cors_headers_get }} + add_header 'Cache-Control' 'no-cache'; + add_header 'Content-Type' 'text/event-stream'; + add_header 'Connection' 'keep-alive'; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "upgrade"; + proxy_buffering off; + proxy_cache off; + proxy_read_timeout 36000s; + {{ $proxy_settings }} + {{ $cors_headers_options }} + {{ $cors_headers_post }} + {{ $cors_headers_get }} } # Error pages