HostingHostBuilderExtensions.UseEnvironment(IHostBuilder, String) HostingHostBuilderExtensions.UseEnvironment(IHostBuilder, String) HostingHostBuilderExtensions.UseEnvironment(IHostBuilder, String) Method

Definition

Specify the environment to be used by the host.

public static Microsoft.Extensions.Hosting.IHostBuilder UseEnvironment (this Microsoft.Extensions.Hosting.IHostBuilder hostBuilder, string environment);
static member UseEnvironment : Microsoft.Extensions.Hosting.IHostBuilder * string -> Microsoft.Extensions.Hosting.IHostBuilder
<Extension()>
Public Function UseEnvironment (hostBuilder As IHostBuilder, environment As String) As IHostBuilder

Parameters

hostBuilder
IHostBuilder IHostBuilder IHostBuilder

The IHostBuilder to configure.

environment
String String String

The environment to host the application in.

Returns

Applies to