You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
I should get a warning if my memory_limit of the local php used by composer is insufficient #1343
I am too stupid to already have a well configured PHP environment before starting developing projects for shopware and this CLI looks like it was made for exactly this person. I would like a warning if my local composers php has insufficient memory.
I scaffolded via: shopware-cli project create testshop --no-interaction --docker and ran it via shopware-cli proejct dev up which worked fine. It even tells me my Runtime Memory Limit is fine:
Now that probably refers to the container environment (the runtime) which is why this is a Story and not a Bug.
But when I now run composer require shopware/docker --no-interaction locally it throws:
[KO]
Script assets:install returned with error code 255
!! Warning: Failed to load plugins Error message: An exception occurred in the driver: SQLSTATE[HY000] [2002] No such file or directory
!!
!! Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /tmp/test-gitlab/test2/testshop/vendor/symfony/framework-bundle/DependencyInjection/Compiler/ContainerBuilderDebugDumpPass.php on line 52
!!
!! Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 32768 bytes) in /tmp/test-gitlab/test2/testshop/vendor/symfony/error-handler/Error/OutOfMemoryError.php on line 1
!!
Script @auto-scripts was called via post-update-cmd
I would like a warning that is independent of the runtime check.
Acceptance criteria
An "memory limit" healthcheck additionally happens under "Local behaviour"just like for the runtime.
Also, I couldn't really find this memory limit requirement in the docks, it may make sense to state this somewhere in the CLIs documentation because I did not read legacy setup or hosting guides when starting developing with this and it seems to be a rather important setting:
I guess we miss here documentation. You should run composer inside the Container. docker compose exec web bash and there the actual composer commands. Than it has all correct environment
I guess we miss here documentation. You should run composer inside the Container. docker compose exec web bash and there the actual composer commands. Than it has all correct environment
I thought about it but this volume mount suggested I could do either:
web:
volumes:
- .:/var/www/html
And yes, if you do want people to run all their composer / php commands in the web container via a docker exec that should be documented, exec into the web service to run composer wasn't intuitive for me. And while you don't need it often, it's also a bit cumbersome.
Generally, I would also advocate for "freedom of choice" on how developers use the tools you provide. And while I do see point in steering people into the right direction when developing for a product you probably know best yourself, different people write code in different ways, given the resources I would try to support them in their choice.
If you really do want people to go through the container, maybe give people an shopware-cli composer <args> command that just takes the input arguments 1:1 and routes them wherever you see fit. Someone from us could probably create PR for something like that and internally we could add an alias for composer = shopware-cli composer and prevent Claude to do stupid things in our AI-workflows.
Activity
insid1ous-admin commentedon Aug 9, 2026
Also, I couldn't really find this memory limit requirement in the docks, it may make sense to state this somewhere in the CLIs documentation because I did not read legacy setup or hosting guides when starting developing with this and it seems to be a rather important setting:
(or maybe i missed it)
shyim commentedon Aug 10, 2026
I guess we miss here documentation. You should run
composerinside the Container.docker compose exec web bashand there the actual composer commands. Than it has all correct environmentinsid1ous-admin commentedon Aug 10, 2026
I thought about it but this volume mount suggested I could do either:
And yes, if you do want people to run all their composer / php commands in the web container via a docker exec that should be documented,
execinto thewebservice to run composer wasn't intuitive for me. And while you don't need it often, it's also a bit cumbersome.Generally, I would also advocate for "freedom of choice" on how developers use the tools you provide. And while I do see point in steering people into the right direction when developing for a product you probably know best yourself, different people write code in different ways, given the resources I would try to support them in their choice.
If you really do want people to go through the container, maybe give people an
shopware-cli composer <args>command that just takes the input arguments 1:1 and routes them wherever you see fit. Someone from us could probably create PR for something like that and internally we could add an alias forcomposer=shopware-cli composerand prevent Claude to do stupid things in our AI-workflows.shyim commentedon Aug 12, 2026
insid1ous-admin i guess i would document this for now and not change anything inside cli yet 👀
shopware/docs#2436
what do you think?
docs: document Composer-in-container and PHP memory limit for CLI Doc…
shyim commentedon Sep 25, 2026
In the meanwhile we updated the docs and added also the alias