The environment for .Net Core applications can be determined via environment variables.
.Net Core applications use the “ASPNETCORE_ENVIRONMENT” value for determining the environment profile. This profile is very important and can be used to determine many application settings or for specific error pages and exception handling.