-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Load an .env file based on environment #14
Comments
A possible serious proposal: new EnvLoader().LoadEnv();
The It should be noted that the default environment will be "development" or "dev" if the environment is never specified with |
MrDave1999
added a commit
that referenced
this issue
Feb 1, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 1, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 1, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 2, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 2, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 2, 2022
This was referenced Feb 8, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 17, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 17, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 17, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 17, 2022
MrDave1999
added a commit
that referenced
this issue
Feb 17, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Normally you have files like: .env.dev, .env.test and .env.staging, so you should load the .env file based on your environment. This environment can be defined through an environment variable such as
DOTNET_ENV
.For example:
export DOTNET_ENV=staging
This feature can be achieved without modifying the library such as:
In a future version this feature could be added so that it is not necessary to add this line:
The text was updated successfully, but these errors were encountered: