From c10353f6d5329acc15338eb651d7342292694cc3 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Wed, 26 May 2021 16:23:19 +0200 Subject: [PATCH 1/2] bump tus limit to 100G --- docker/nginx/conf.d/client.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/nginx/conf.d/client.conf b/docker/nginx/conf.d/client.conf index d45d0a00..4e9cf918 100644 --- a/docker/nginx/conf.d/client.conf +++ b/docker/nginx/conf.d/client.conf @@ -390,7 +390,7 @@ server { location /skynet/tus { include /etc/nginx/conf.d/include/cors; - client_max_body_size 1000M; # make sure to limit the size of upload to a sane value + client_max_body_size 100G; # make sure to limit the size of upload to a sane value proxy_read_timeout 600; proxy_request_buffering off; # stream uploaded files through the proxy as it comes in proxy_set_header Expect $http_expect; From 2db2ae60f6a19b6b63fa9dd7138538599d5ef7ac Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Wed, 26 May 2021 18:02:32 +0200 Subject: [PATCH 2/2] adjust tus request max body size --- docker/nginx/conf.d/client.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docker/nginx/conf.d/client.conf b/docker/nginx/conf.d/client.conf index 4e9cf918..f5373143 100644 --- a/docker/nginx/conf.d/client.conf +++ b/docker/nginx/conf.d/client.conf @@ -390,13 +390,15 @@ server { location /skynet/tus { include /etc/nginx/conf.d/include/cors; - client_max_body_size 100G; # make sure to limit the size of upload to a sane value + client_max_body_size 50M; # tus chunks size is 40M + leaving 10M of breathing room proxy_read_timeout 600; proxy_request_buffering off; # stream uploaded files through the proxy as it comes in proxy_set_header Expect $http_expect; # proxy /skynet/tus requests to siad endpoint with all arguments proxy_pass http://siad; + + # rewrite tus headers to use correct uri proxy_redirect https://siad/ https://$domain.$tld/; }