From 6271b64c3743bcf2127befda70b89d29624bef90 Mon Sep 17 00:00:00 2001 From: mbugeia Date: Fri, 31 Oct 2014 01:05:13 +0100 Subject: [PATCH] Fix upload limit in wordpress --- conf/nginx.conf | 5 +++-- conf/nginx.conf-public | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 90936aa..1188e95 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -4,11 +4,12 @@ location PATHTOCHANGE { rewrite ^ https://$server_name$request_uri? permanent; } index index.php; - if (!-e $request_filename) + if (!-e $request_filename) { rewrite ^(.+)$ PATHTOCHANGE/index.php?q=$1 last; } - location ~ [^/]\.php(/|$) { + client_max_body_size 30m; + location ~ [^/]\.php(/|$) { fastcgi_split_path_info ^(.+?\.php)(/.*)$; fastcgi_pass unix:/var/run/php5-fpm.sock; fastcgi_index index.php; diff --git a/conf/nginx.conf-public b/conf/nginx.conf-public index 19c5077..a98bca5 100644 --- a/conf/nginx.conf-public +++ b/conf/nginx.conf-public @@ -1,10 +1,11 @@ location PATHTOCHANGE { alias ALIASTOCHANGE; index index.php; - if (!-e $request_filename) + if (!-e $request_filename) { rewrite ^(.+)$ PATHTOCHANGE/index.php?q=$1 last; } + client_max_body_size 30m; location ~ [^/]\.php(/|$) { fastcgi_split_path_info ^(.+?\.php)(/.*)$; fastcgi_pass unix:/var/run/php5-fpm.sock;