From 885ddfddd0dec04909e152c4476269a405f482cc Mon Sep 17 00:00:00 2001 From: Tan Jiang Date: Fri, 4 Aug 2017 21:22:22 +0800 Subject: [PATCH] enable buffer on nginx --- make/common/templates/nginx/nginx.http.conf | 8 +++++--- make/common/templates/nginx/nginx.https.conf | 6 ++++-- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/make/common/templates/nginx/nginx.http.conf b/make/common/templates/nginx/nginx.http.conf index 213f3afd5..e25db141e 100644 --- a/make/common/templates/nginx/nginx.http.conf +++ b/make/common/templates/nginx/nginx.http.conf @@ -59,9 +59,11 @@ http { # When setting up Harbor behind other proxy, such as an Nginx instance, remove the below line if the proxy already has similar settings. proxy_set_header X-Forwarded-Proto $$scheme; - - proxy_buffering off; - proxy_request_buffering off; + + proxy_buffer_size 4k; + proxy_buffers 4 32k; + proxy_busy_buffers_size 64k; + proxy_temp_file_write_size 64k; } location /service/ { diff --git a/make/common/templates/nginx/nginx.https.conf b/make/common/templates/nginx/nginx.https.conf index 3e3c829e5..fe8d50ec8 100644 --- a/make/common/templates/nginx/nginx.https.conf +++ b/make/common/templates/nginx/nginx.https.conf @@ -79,8 +79,10 @@ http { # When setting up Harbor behind other proxy, such as an Nginx instance, remove the below line if the proxy already has similar settings. proxy_set_header X-Forwarded-Proto $$scheme; - proxy_buffering off; - proxy_request_buffering off; + proxy_buffer_size 4k; + proxy_buffers 4 32k; + proxy_busy_buffers_size 64k; + proxy_temp_file_write_size 64k; } location /service/ {