From dd856ecf5086534fc81018a4c751279b0cd04a82 Mon Sep 17 00:00:00 2001 From: Yamila Moreno Date: Mon, 23 Feb 2026 12:16:47 +0100 Subject: [PATCH] :recycle: Deprecate PENPOT_HTTP_SERVER_MAX_MULTIPART_BODY_SIZE envvar --- CHANGES.md | 3 +++ docker/images/docker-compose.yaml | 8 +++----- docker/images/files/nginx-entrypoint.sh | 4 ++-- docker/images/files/nginx.conf.template | 2 +- docs/technical-guide/getting-started/docker.md | 4 ++-- 5 files changed, 11 insertions(+), 10 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 3c17cf5ccd..50913a1bb4 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -2,6 +2,9 @@ ## 2.14.0 (Unreleased) +### :boom: Breaking changes & Deprecations +- Deprecate `PENPOT_HTTP_SERVER_MAX_MULTIPART_BODY_SIZE` in favour of `PENPOT_HTTP_SERVER_MAX_BODY_SIZE`. + ### :sparkles: New features & Enhancements - Access to design tokens in Penpot Plugins [Taiga #8990](https://tree.taiga.io/project/penpot/us/8990) diff --git a/docker/images/docker-compose.yaml b/docker/images/docker-compose.yaml index 8076064b94..5d3b84d09c 100644 --- a/docker/images/docker-compose.yaml +++ b/docker/images/docker-compose.yaml @@ -30,11 +30,9 @@ x-uri: &penpot-public-uri PENPOT_PUBLIC_URI: http://localhost:9001 x-body-size: &penpot-http-body-size - # Max body size (30MiB); Used for plain requests, should never be - # greater than multi-part size - PENPOT_HTTP_SERVER_MAX_BODY_SIZE: 31457280 - - # Max multipart body size (350MiB) + # Max body size + PENPOT_HTTP_SERVER_MAX_BODY_SIZE: 367001600 + # Deprecation warning: this variable is deprecated. Use PENPOT_HTTP_SERVER_MAX_BODY (defaults to 367001600) PENPOT_HTTP_SERVER_MAX_MULTIPART_BODY_SIZE: 367001600 ## Penpot SECRET KEY. It serves as a master key from which other keys for subsystems diff --git a/docker/images/files/nginx-entrypoint.sh b/docker/images/files/nginx-entrypoint.sh index 39546de336..4512d06495 100644 --- a/docker/images/files/nginx-entrypoint.sh +++ b/docker/images/files/nginx-entrypoint.sh @@ -30,8 +30,8 @@ update_flags /var/www/app/js/config.js export PENPOT_BACKEND_URI=${PENPOT_BACKEND_URI:-http://penpot-backend:6060} export PENPOT_EXPORTER_URI=${PENPOT_EXPORTER_URI:-http://penpot-exporter:6061} export PENPOT_NITRATE_URI=${PENPOT_NITRATE_URI:-http://penpot-nitrate:3000} -export PENPOT_HTTP_SERVER_MAX_MULTIPART_BODY_SIZE=${PENPOT_HTTP_SERVER_MAX_MULTIPART_BODY_SIZE:-367001600} # Default to 350MiB -envsubst "\$PENPOT_BACKEND_URI,\$PENPOT_EXPORTER_URI,\$PENPOT_NITRATE_URI,\$PENPOT_HTTP_SERVER_MAX_MULTIPART_BODY_SIZE" \ +export PENPOT_HTTP_SERVER_MAX_BODY_SIZE=${PENPOT_HTTP_SERVER_MAX_BODY_SIZE:-367001600} # Default to 350MiB +envsubst "\$PENPOT_BACKEND_URI,\$PENPOT_EXPORTER_URI,\$PENPOT_NITRATE_URI,\$PENPOT_HTTP_SERVER_MAX_BODY_SIZE" \ < /tmp/nginx.conf.template > /etc/nginx/nginx.conf PENPOT_DEFAULT_INTERNAL_RESOLVER="$(awk 'BEGIN{ORS=" "} $1=="nameserver" { sub(/%.*$/,"",$2); print ($2 ~ ":")? "["$2"]": $2}' /etc/resolv.conf)" diff --git a/docker/images/files/nginx.conf.template b/docker/images/files/nginx.conf.template index a623408dcd..d0b7bc3b1f 100644 --- a/docker/images/files/nginx.conf.template +++ b/docker/images/files/nginx.conf.template @@ -76,7 +76,7 @@ http { listen [::]:8080 default_server; server_name _; - client_max_body_size $PENPOT_HTTP_SERVER_MAX_MULTIPART_BODY_SIZE; + client_max_body_size $PENPOT_HTTP_SERVER_MAX_BODY_SIZE; charset utf-8; etag off; diff --git a/docs/technical-guide/getting-started/docker.md b/docs/technical-guide/getting-started/docker.md index 2e82d8d629..53560235d3 100644 --- a/docs/technical-guide/getting-started/docker.md +++ b/docs/technical-guide/getting-started/docker.md @@ -188,8 +188,8 @@ server { server_name penpot.mycompany.com; # This value should be in sync with the corresponding in the docker-compose.yml - # PENPOT_HTTP_SERVER_MAX_BODY_SIZE: 31457280 - client_max_body_size 31457280; + # PENPOT_HTTP_SERVER_MAX_BODY_SIZE: 367001600 + client_max_body_size 367001600; # Logs: Configure your logs following the best practices inside your company access_log /path/to/penpot.access.log;