Yves payload too large
Hello, when I try to upload file bigger than 1MB I get an error on Yves side that the Payload is too large. Where that can be configured?
Answers
-
By default is 128M, so , it's weird that output. Could you please share where you're trying to upload the file from?
To change the default config, open your deploy.dev.yml file and in the php image, set, for example
image: tag: spryker/php:8.2 php: ini: "upload_max_filesize": "248M" "post_max_size": "248M"
the run
docker/sdk boot deploy.dev.yml
and docker/sdk up
0 -
Hey Hidran, thank you for the answer.
It is a /register route on B2B shop when new customer is registering. We added a file which is being sent in payload as binary. It's local file being uploaded.0 -
If I try to do this ini modifications, it still throws so I guess it comes from somewhere else. I somehow feel that it is thrown already on nginx level or so, and it doesn't reach PHP at all. Interestingly it throws me failwhale even though debugging mode is on.
0 -
Are you working on a local environment?
As I told you before, by default is 128M. So, it's really weird to have that response form 1Mb.
0 -
I think I figured it out. It is a default value for yves and I overwrote it like this in deploy.dev.yml
http:
max-request-body-size: 10mAccording to the deploy file reference :
groups: applications: application: http: max-request-body-size: - defines the maximum allowed size of the request body that can be sent to the application, in MB. If not specified, the default values apply:
backoffice - 10m
merchant-portal - 10m
glue-storefront - 10m
glue-backend - 10m
glue - 2m
yves - 1mAnd these values seems to be correct for me and worked after I configured it as mentioned.
1 -
Hi ivan-jurisic, can you try it like this?
Put this on top of deploy.dev.yml file, just under the version.
x-file-upload-limit-yves: &yves-max-file-size "40M"
Then add this under yves_eu β httpyves_eu: application: yves http: max-request-body-size: *yves-max-file-size
We had same issue, this helped. Just do docker/sdk boot deploy.dev.yml and docker/sdk up.
3 -
Hey @andrej.jelinic we post it in the same minute almost :D
Thanks. Yes, that's exactly what is solving the issue. I appreciate your help.1
Categories
- All Categories
- 42 Getting Started & Guidelines
- 7 Getting Started in the Community
- 8 Additional Resources
- 7 Community Ideas and Feedback
- 69 Spryker News
- 896 Developer Corner
- 758 Spryker Development
- 83 Spryker Dev Environment
- 361 Spryker Releases
- 3 Oryx frontend framework
- 34 Propel ORM
- 68 Community Projects
- 3 Community Ideation Board
- 30 Hackathon
- 3 PHP Bridge
- 6 Gacela Project
- 23 Job Opportunities
- 3.2K π Slack Archives
- 116 Academy
- 5 Business Users
- 370 Docker
- 551 Slack General
- 2K Help
- 75 Knowledge Sharing
- 6 Random Stuff
- 4 Code Testing
- 32 Product & Business Questions
- 68 Spryker Safari Questions
- 50 Random