Explorar el Código

[nanobox] Allow Full-size Uploads (#4123)

The Nginx configurations used by Nanobox previously neglected to increase the default upload size limit. This PR bumps that value up to the current Mastodon limit of 8MiB.
Daniel Hunsaker hace 7 años
padre
commit
f68fa930ea
Se han modificado 3 ficheros con 10 adiciones y 6 borrados
  1. 4 2
      nanobox/nginx-local.conf
  2. 2 2
      nanobox/nginx-stream.conf.erb
  3. 4 2
      nanobox/nginx-web.conf.erb

+ 4 - 2
nanobox/nginx-local.conf

@@ -27,8 +27,8 @@ http {
     }
 
     map $http_upgrade $connection_upgrade {
-      default upgrade;
-      ''      close;
+        default upgrade;
+        ''      close;
     }
 
     # Configuration for Nginx
@@ -38,6 +38,8 @@ http {
 
         root /app/public;
 
+        client_max_body_size 8M;
+
         location / {
             try_files $uri @rails;
         }

+ 2 - 2
nanobox/nginx-stream.conf.erb

@@ -22,8 +22,8 @@ http {
     }
 
     map $http_upgrade $connection_upgrade {
-      default upgrade;
-      ''      close;
+        default upgrade;
+        ''      close;
     }
 
     # Configuration for Nginx

+ 4 - 2
nanobox/nginx-web.conf.erb

@@ -22,8 +22,8 @@ http {
     }
 
     map $http_upgrade $connection_upgrade {
-      default upgrade;
-      ''      close;
+        default upgrade;
+        ''      close;
     }
 
     # Configuration for Nginx
@@ -36,6 +36,8 @@ http {
 
         root /app/public;
 
+        client_max_body_size 8M;
+
         location / {
             try_files $uri @rails;
         }