I can't seem to find any sort of official list of the APP_ENV variable in the .env file. In practice I've used local, dev, development, staging, and production. And I feel like this works okay... and I've even seen some of these used by other prominent Laravel developers. However I'd feel much more confident if there was a standard. Is there a PSR standard that defines environment names? Or maybe some Laravel documentation I'm missing?
The . env file contains the individual user environment variables that override the variables set in the /etc/environment file. You can customize your environment variables as desired by modifying your . env file.
env file is placed at the base of the project directory. Project directory can be explicitly defined with the --file option or COMPOSE_FILE environment variable.
As far as I know, only local, testing and production are standard, because the Illuminate/Foundation/Application class contains the methods isLocal(), runningUnitTests() and isProduction() for checking them.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With