andres-montanez / Magallanes

The PHP Deployment Tool
https://magephp.com
MIT License
691 stars 169 forks source link

SYMFONY_ENV defaults to dev on deploy #411

Closed fullbl closed 2 years ago

fullbl commented 6 years ago

Hi, when deploying with mage, I would like to install composer dependencies without dev, but bin/console is executed with dev environment because: $env = $input->getParameterOption(['--env', '-e'], getenv('SYMFONY_ENV') ?: 'dev');

It seems that parameter symfony: { env: 'prod' } is not taken into consideration. Shouldn't be better to change environment at beginning of deploy and reset it at exit? Also, deploying alters our local vendor folder, wouldn't be better to use a temporary directory?

Many thanks for your work!

andres-montanez commented 6 years ago

Hi, I wasn't able to reproduce this. Can you share configuration and logs? Thanks.

benr77 commented 5 years ago

For Symfony 4, SYMFONY_ENV has become APP_ENV.