feat: make client_max_body_size configurable via env (#1029)

This commit is contained in:
Bernhard Sirlinger
2022-12-26 22:42:22 +01:00
committed by GitHub
parent 75e44ba902
commit 8f7b234a12
5 changed files with 8 additions and 1 deletions

View File

@@ -44,6 +44,7 @@ FROM nginxinc/nginx-unprivileged:1.23.3-alpine as frappe
# Set default ENV variables for backwards compatibility
ENV PROXY_READ_TIMOUT=120
ENV CLIENT_MAX_BODY_SIZE=50m
# https://github.com/nginxinc/docker-nginx-unprivileged/blob/main/stable/alpine/20-envsubst-on-templates.sh
COPY nginx-template.conf /etc/nginx/templates/default.conf.template

View File

@@ -87,7 +87,7 @@ server {
# optimizations
sendfile on;
keepalive_timeout 15;
client_max_body_size 50m;
client_max_body_size ${CLIENT_MAX_BODY_SIZE};
client_body_buffer_size 16K;
client_header_buffer_size 1k;