From 81a6a7cbf6e0ef1b4e968eb04a717b4e68beea35 Mon Sep 17 00:00:00 2001 From: hoellen Date: Mon, 25 Jun 2018 15:51:20 +0200 Subject: [PATCH 1/2] Use message_size variable from env for webmail --- core/nginx/conf/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/nginx/conf/nginx.conf b/core/nginx/conf/nginx.conf index 8b3d9be1..d1103f79 100644 --- a/core/nginx/conf/nginx.conf +++ b/core/nginx/conf/nginx.conf @@ -92,7 +92,7 @@ http { rewrite ^({{ WEB_WEBMAIL }})$ $1/ permanent; rewrite ^{{ WEB_WEBMAIL }}/(.*) /$1 break; include /etc/nginx/proxy.conf; - client_max_body_size 30M; + client_max_body_size {{ MESSAGE_SIZE_LIMIT }}; proxy_pass http://$webmail; } {% endif %} From c51e1b9eefb6f59cdeff7ba284cb413ea4afc65e Mon Sep 17 00:00:00 2001 From: hoellen Date: Thu, 28 Jun 2018 19:23:08 +0200 Subject: [PATCH 2/2] webmail client_max_body_size with message_size_limit and 8M tolerance --- core/nginx/conf/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/nginx/conf/nginx.conf b/core/nginx/conf/nginx.conf index d1103f79..b779f98e 100644 --- a/core/nginx/conf/nginx.conf +++ b/core/nginx/conf/nginx.conf @@ -92,7 +92,7 @@ http { rewrite ^({{ WEB_WEBMAIL }})$ $1/ permanent; rewrite ^{{ WEB_WEBMAIL }}/(.*) /$1 break; include /etc/nginx/proxy.conf; - client_max_body_size {{ MESSAGE_SIZE_LIMIT }}; + client_max_body_size {{ MESSAGE_SIZE_LIMIT|int + 8388608 }}; proxy_pass http://$webmail; } {% endif %}