Enable nginx proxy server and set file upload size

Enable nginx proxy server and set file upload size

Edit the respective .conf nginx file in your favorite editor. Add the following code below the .conf file to add the proxy server navigation. By default, the max file upload size is set to 1MB.
To change the default setting for the targeted server, change the value of `client_max_body_size` to the desired size.

server {
    server_name exampleServerName.com;
    location / {
        proxy_set_header Access-Control-Allow-Origin "*";
        proxy_pass http://localhost;
    }
    client_max_body_size 20M; # Default is 1MB. Increase it to the desired size
}

Reference Link: Nginx Documentation

Leave a Reply

Your email address will not be published. Required fields are marked *