capistrano / symfony

Capistrano tasks for deploying the Symfony standard edition
MIT License
353 stars 65 forks source link

Exporting of SYMFONY_ENV #42

Closed zaerl closed 6 years ago

zaerl commented 9 years ago

It seems that capistrano/symfony do not export the SYMFONY_ENV variable. Given this post-install-cmd scripts do not run in the chosen environment. I set this in my deploy script and now everything work well.

   set :default_env, {
     'SYMFONY_ENV' => 'prod'
   }
webdevilopers commented 8 years ago

Is this still an issue? Had no problems so far with the default config value:

# Symfony environment
set :symfony_env,  "prod"

Can you post any post-install-cmd script that fails?

sagikazarmark commented 8 years ago

This is what I can see in the capistrano log:

  INFO [d970e0e3] Running MY_PATH/shared/composer.phar install --no-dev --prefer-dist --no-interaction --quiet --optimize-autoloader as user@host
 DEBUG [d970e0e3] Command: cd MY_PATH/releases/20160318111655 && ( export SYMFONY_ENV="prod" ; MY_PATH/shared/composer.phar install --no-dev --prefer-dist --no-interaction --quiet --optimize-autoloader )
  INFO [d970e0e3] Finished in 9.869 seconds with exit status 0 (successful).

This is actually done here