共用方式為


AzureCosmosExtensions.WithGatewayPort Method

Definition

Configures the gateway port for the Azure Cosmos DB emulator.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureCosmosDBEmulatorResource> WithGatewayPort (this Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureCosmosDBEmulatorResource> builder, int? port);
static member WithGatewayPort : Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureCosmosDBEmulatorResource> * Nullable<int> -> Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureCosmosDBEmulatorResource>
<Extension()>
Public Function WithGatewayPort (builder As IResourceBuilder(Of AzureCosmosDBEmulatorResource), port As Nullable(Of Integer)) As IResourceBuilder(Of AzureCosmosDBEmulatorResource)

Parameters

builder
IResourceBuilder<AzureCosmosDBEmulatorResource>

Builder for the Cosmos emulator container

port
Nullable<Int32>

Host port to bind to the emulator gateway port.

Returns

Cosmos emulator resource builder.

Applies to