Use config environments
samdark opened this issue · comments
Alexander Makarov commented
We need to use config environments feature and have 2 default set of configs - dev (debug) and prod. Selecting one should be done through YII_ENV environmental variable (or .env).
Same should be applied to all templates and demo apps.
Alexander Makarov commented
Sergei Predvoditelev commented
Also need environment "test"
Alexander Makarov commented
We should also get YII_ENV through getenv and not trough $_ENV since it's not populated by default. See https://mattallan.me/posts/how-php-environment-variables-actually-work/
Alexander Borisov commented
Looks like there is a problem with getenv and nginx fastcgi_param
Alexander Makarov commented
Yeah. May consider configuring it to fill getenv() or using https://github.com/symfony/dotenv.