I want to increase the client_max_body_size
parameter for a specific location.
I tried to do something like that in the location
location / {
proxy_pass http://dashboard-app;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto https;
proxy_cache_bypass $http_upgrade;
location /admin/upload {
client_max_body_size 10m;
}
}
the problem is that there is no proxy_pass
or all other modules in the /admin/upload
location, so I'm gettings 404
for that route.
I know I can just add all the modules inside that location, but it's just a duplication of code which seemds useless to me.
How can I inherit the base location modules to the upload location conf?