Environment Variable Placeholders

To avoid storing secret credentials directly in configuration files, environment variables are often used to inject these values into the application process. This technique is especially useful in Cloud environments.

Instead of specifying actual values in the configuration, you can use environment variable placeholders, which follow the following convention in which EnvironmentVariable is the name of the environment variable to use.

"${EnvironmentVariable}"

The following is a configuration example that uses environment variables.

"Authentication": {
   "Type": "${ENV-AUTH-TYPE}",
   "TenantId": "${ENV-TENANT-ID}",
   "ClientId": "${ENV-CLIENT-ID}",
   "ClientSecret": "${ENV-CLIENT-SECRET}" }