How would environment specific .env like .env.testing tell laravel that the environment is should act the same as it being development or local and not show errors like
APP_DEBUG is set to true while APP_ENV is not local
Additional Environment Files
Before loading your application's environment variables, Laravel determines if either the APP_ENV environment variable has been externally provided or if the --env CLI argument has been specified. If so, Laravel will attempt to load an .env.[APP_ENV] file if it exists. If it does not exist, the default .env file will be loaded.
@Snapey
Thnx as always you rock. but i dont think i am explaining my issue correctly.
I have a pretty large CICD built and have 6 different environments.
I have some called
only_content
stage
When i put those names in the .env they work great. no issues.
ENV=stage
ENV=only_content
Here is my issue. when i try to set another one as QA which i need to have debug features active on the server instance just like development or local the app loads with the error
APP_DEBUG is set to true while APP_ENV is not local
There are also other errors in my test files when they are ran.
If i change the ENV to development the app loads and works the way it should.
So my question is how do i make a custom environment act like development or local act and allow my app to load and allow tests to run the way they were created to run?
I do not but i will install it. If you want to replicate it just set your environment to anything other then develop or local and turn debug on. you will see it in the home page or root