Deployment failure
Ersian-zz opened this issue · comments
When I deploy I got this error:
Fatal error: Uncaught RuntimeException: Command php bin/magento setup:di:compile-multi-tenant returned code 1 in /app/public/vendor/platformsh/magento2-configuration/Platformsh.php:423
Stack trace:
#0 /app/public/vendor/platformsh/magento2-configuration/Platformsh.php(116): Platformsh\Magento\Platformsh->execute('php bin/magento...')
#1 /app/public/vendor/platformsh/magento2-configuration/Platformsh.php(93): Platformsh\Magento\Platformsh->compile()
#2 /app/public/vendor/platformsh/magento2-configuration/magento-build.php(6): Platformsh\Magento\Platformsh->build()
#3 {main}
thrown in /app/public/vendor/platformsh/magento2-configuration/Platformsh.php on line 423
[InvalidArgumentException]
Command "setup:di:compile-multi-tenant" is not defined.
Did you mean one of these?
setup:di:compile
module:disable
maintenance:disable
Shouldn't be setup:di:compile
instead of setup:di:compile-multi-tenant
?
I'm on Magento 2.1.2 and use the dev-master
version of Platformsh in composer.
Same Issue here
There are a couple issues like this, from what I remember. I eventually rolled my own, but copied 90% of it.
edit: I think it's supposed to be more like an example script. Every M2 site is different and you can't rely on using this Composer package (as you can't overwrite tasks or anything).
The problem here is this config is based on Magento 2 EE and most of us run the community edition. Just fork or vendor it and change:
$this->execute("php bin/magento setup:di:compile-multi-tenant");
to:
$this->execute("php bin/magento setup:di:compile");
And be sure to update your .platform.app.yaml
file to reference the new paths under the vendor
directory. You'll most likely run into other problems with env.php
or the database so I'd just go with what @erfanimani said and copy this repo into yours and start modifying the tasks to suit your particular setup.