Search code examples
javaspringamazon-web-servicesamazon-elastic-beanstalk

How to solve 413 request entity too large


When I post a form with an image taken from my phone I reserve the error "413 request entity too large" I realize that an image included in the form taken by the phone camera is too large, and the server rejects the request... but how can I fix this issue, I'm using Java Spring framework, and MySQL database, all of this handled with Amazon aws services.


Solution

  • You have to modify your .platform as shown in the docs.

    For example, you could have the following .platform/nginx/conf.d/myconfig.conf with content:

    client_max_body_size 20M;