diff --git a/deployment/roles/reverse/templates/nginx/conf.d/vhosts.conf.j2 b/deployment/roles/reverse/templates/nginx/conf.d/vhosts.conf.j2 index f8595f93c77..8656ad19988 100644 --- a/deployment/roles/reverse/templates/nginx/conf.d/vhosts.conf.j2 +++ b/deployment/roles/reverse/templates/nginx/conf.d/vhosts.conf.j2 @@ -60,6 +60,16 @@ server { # Please be aware that browsers cannot correctly display this error. # Setting size to 0 disables checking of client request body size. client_max_body_size 0; + + # Increase send timeout to allow the upstream more time to consume the stream. + # This prevents "Early EOF" errors during large uploads if the backend slows down. + # Note: This is a timeout between two successive write operations, not for the total duration. + proxy_send_timeout 600s; + + # Increase read timeout to allow the backend to process the file after the upload is complete. + # Essential for large ZIPs where post-upload tasks can take some time. + # Note: This is a timeout between two successive read operations from the upstream. + proxy_read_timeout 600s; } {% endif %} @@ -101,6 +111,16 @@ server { # Please be aware that browsers cannot correctly display this error. # Setting size to 0 disables checking of client request body size. client_max_body_size 0; + + # Increase send timeout to allow the upstream more time to consume the stream. + # This prevents "Early EOF" errors during large uploads if the backend slows down. + # Note: This is a timeout between two successive write operations, not for the total duration. + proxy_send_timeout 600s; + + # Increase read timeout to allow the backend to process the file after the upload is complete. + # Essential for large ZIPs where post-upload tasks can take some time. + # Note: This is a timeout between two successive read operations from the upstream. + proxy_read_timeout 600s; } {% endif %} {% if groups.get('hosts_ui_design_system', []) | length > 0 %}