Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Relax nginx/php config in both ddev-webserver and ddev-router #1507

Closed
rfay opened this issue Mar 26, 2019 · 3 comments
Closed

Relax nginx/php config in both ddev-webserver and ddev-router #1507

rfay opened this issue Mar 26, 2019 · 3 comments
Labels
Prioritized We expect to do this in an upcoming release
Milestone

Comments

@rfay
Copy link
Member

rfay commented Mar 26, 2019

Describe the bug

Most of the packet-size limitations in nginx/apache/php are intended to prevent server abuse or overuse by malicious clients or bad code. But those aren't really goals for ddev, so it would be useful to a few people to:

  • Set nginx's client_max_body_size to 0 (disabling that feature) on both ddev-webserver and ddev-router.
  • Increase php upload_max_filesize and post_max_size
  • Increase php max_input_vars
  • I don't think there's an equivalent apache config, but it's worth looking.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Version and configuration information (please complete the following information):

  • Host computer OS and Version: [e.g. Windows 10, macOS High Sierra]
  • Docker version information (use docker version) and insert it here.
  • ddev version information (use ddev version)
  • config.yaml contents for the misbehaving project
  • Do you have any custom configuration (nginx, php, mysql) in the .ddev folder? If so, have you tried without them?

Additional context
Add any other context about the problem here. Thanks!

@rfay rfay added the Prioritized We expect to do this in an upcoming release label Mar 26, 2019
@RobertLang
Copy link

The limit in Apache is set via the LimitRequestBody directive and defaults to 0, so this should be ok.

However there is another Config which could be set to 0: LimitXMLRequestBody (Default: 1 M)
https://httpd.apache.org/docs/trunk/de/mod/core.html#limitxmlrequestbody

Personally I never had a problem with the XML body size.

@rfay
Copy link
Member Author

rfay commented Mar 26, 2019

Thanks @RobertLang - Could you say more about the situation where you hit the client_max_body_size problem in the router? I wasn't familiar with the technology you were testing.

@RobertLang
Copy link

I was integrating a resumable file upload for larger files using the tus protokoll (https://tus.io/) and tus-php (https://github.com/ankitpokhrel/tus-php).
Everything worked nicely until I hit the 100 M barrier configured in the ddev-router. The router returned an error: Nginx: 413 – Request Entity Too Large which, after doing some research on google, led me to the solution to change the client_max_body_size on the ddev-router container.
After changing that value uploads with several gigs of data were possible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Prioritized We expect to do this in an upcoming release
Projects
None yet
Development

No branches or pull requests

2 participants