Chapter 4. Environment variables for .NET 9.0
The .NET images support several environment variables to control the build behavior of your .NET application. You can set these variables as part of the build configuration, or add them to the .s2i/environment
file in the application source code repository.
Variable Name | Description | Default |
---|---|---|
DOTNET_STARTUP_PROJECT |
Selects the project to run. This must be a project file (for example, |
|
DOTNET_ASSEMBLY_NAME |
Selects the assembly to run. This must not include the |
The name of the |
DOTNET_PUBLISH_READYTORUN |
When set to |
|
DOTNET_RESTORE_SOURCES |
Specifies the space-separated list of NuGet package sources used during the restore operation. This overrides all of the sources specified in the | |
DOTNET_RESTORE_CONFIGFILE |
Specifies a | |
DOTNET_TOOLS |
Specifies a list of .NET tools to install before building the app. It is possible to install a specific version by post pending the package name with | |
DOTNET_TEST_PROJECTS |
Specifies the list of test projects to test. This must be project files or folders containing a single project file. | |
DOTNET_CONFIGURATION |
Runs the application in Debug or Release mode. This value should be either |
|
DOTNET_VERBOSITY |
Specifies the verbosity of the | |
HTTP_PROXY, HTTPS_PROXY | Configures the HTTP or HTTPS proxy used when building and running the application, respectively. | |
DOTNET_RM_SRC |
When set to | |
SSL_CERT_DIR |
Specifies a list of folders or files with additional SSL certificates to trust. The certificates are trusted by each process that runs during the build and all processes that run in the image after the build (including the application that was built). The items can be absolute paths (starting with | |
ASPNETCORE_URLS |
This variable is set to |
|
DOTNET_RESTORE_DISABLE_PARALLEL |
When set to |
|
DOTNET_INCREMENTAL |
When set to |
|
DOTNET_PACK |
When set to |