Table of Contents

Class CloudFoundryHostBuilderExtensions

Namespace
Steeltoe.Extensions.Configuration.CloudFoundry
Assembly
Steeltoe.Extensions.Configuration.CloudFoundryCore.dll
public static class CloudFoundryHostBuilderExtensions
Inheritance
CloudFoundryHostBuilderExtensions
Inherited Members

Methods

AddCloudFoundry(IWebHostBuilder)

Add Cloud Foundry Configuration Provider

[Obsolete("This method will be removed in a future release, please use AddCloudFoundryConfiguration instead")]
public static IWebHostBuilder AddCloudFoundry(this IWebHostBuilder hostBuilder)

Parameters

hostBuilder IWebHostBuilder

Your HostBuilder

Returns

IWebHostBuilder

AddCloudFoundry(IHostBuilder)

Add Cloud Foundry Configuration Provider

[Obsolete("This method will be removed in a future release, please use AddCloudFoundryConfiguration instead")]
public static IHostBuilder AddCloudFoundry(this IHostBuilder hostBuilder)

Parameters

hostBuilder IHostBuilder

Your WebHostBuilder

Returns

IHostBuilder

AddCloudFoundryConfiguration(IWebHostBuilder)

Add Cloud Foundry Configuration Provider

public static IWebHostBuilder AddCloudFoundryConfiguration(this IWebHostBuilder hostBuilder)

Parameters

hostBuilder IWebHostBuilder

Your HostBuilder

Returns

IWebHostBuilder

AddCloudFoundryConfiguration(IHostBuilder)

Add Cloud Foundry Configuration Provider

public static IHostBuilder AddCloudFoundryConfiguration(this IHostBuilder hostBuilder)

Parameters

hostBuilder IHostBuilder

Your WebHostBuilder

Returns

IHostBuilder

UseCloudFoundryHosting(IWebHostBuilder, int?)

Enable the application to listen on port(s) provided by the environment at runtime

[Obsolete("This extension will be removed in a future release. Please use Steeltoe.Common.Hosting.UseCloudHosting() instead")]
public static IWebHostBuilder UseCloudFoundryHosting(this IWebHostBuilder webHostBuilder, int? runLocalPort = null)

Parameters

webHostBuilder IWebHostBuilder

Your WebHostBuilder

runLocalPort int?

Set the port number with code so you don't need to set environment variables locally

Returns

IWebHostBuilder

Your WebHostBuilder, now listening on port(s) found in the environment or passed in

Remarks

runLocalPort parameter will not be used if an environment variable PORT is found