Share via


ComputeBatchModelFactory.BatchInboundNatPool Method

Definition

A inbound NAT Pool that can be used to address specific ports on Compute Nodes in a Batch Pool externally.

public static Azure.Compute.Batch.BatchInboundNatPool BatchInboundNatPool(string name = default, Azure.Compute.Batch.InboundEndpointProtocol protocol = default, int backendPort = 0, int frontendPortRangeStart = 0, int frontendPortRangeEnd = 0, System.Collections.Generic.IEnumerable<Azure.Compute.Batch.NetworkSecurityGroupRule> networkSecurityGroupRules = default);
static member BatchInboundNatPool : string * Azure.Compute.Batch.InboundEndpointProtocol * int * int * int * seq<Azure.Compute.Batch.NetworkSecurityGroupRule> -> Azure.Compute.Batch.BatchInboundNatPool
Public Shared Function BatchInboundNatPool (Optional name As String = Nothing, Optional protocol As InboundEndpointProtocol = Nothing, Optional backendPort As Integer = 0, Optional frontendPortRangeStart As Integer = 0, Optional frontendPortRangeEnd As Integer = 0, Optional networkSecurityGroupRules As IEnumerable(Of NetworkSecurityGroupRule) = Nothing) As BatchInboundNatPool

Parameters

name
String

The name of the endpoint. The name must be unique within a Batch Pool, can contain letters, numbers, underscores, periods, and hyphens. Names must start with a letter or number, must end with a letter, number, or underscore, and cannot exceed 77 characters. If any invalid values are provided the request fails with HTTP status code 400.

protocol
InboundEndpointProtocol

The protocol of the endpoint.

backendPort
Int32

The port number on the Compute Node. This must be unique within a Batch Pool. Acceptable values are between 1 and 65535 except for 29876 and 29877 as these are reserved. If any reserved values are provided the request fails with HTTP status code 400.

frontendPortRangeStart
Int32

The first port number in the range of external ports that will be used to provide inbound access to the backendPort on individual Compute Nodes. Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved. All ranges within a Pool must be distinct and cannot overlap. Each range must contain at least 40 ports. If any reserved or overlapping values are provided the request fails with HTTP status code 400.

frontendPortRangeEnd
Int32

The last port number in the range of external ports that will be used to provide inbound access to the backendPort on individual Compute Nodes. Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved by the Batch service. All ranges within a Pool must be distinct and cannot overlap. Each range must contain at least 40 ports. If any reserved or overlapping values are provided the request fails with HTTP status code 400.

networkSecurityGroupRules
IEnumerable<NetworkSecurityGroupRule>

A list of network security group rules that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch Pool is 25. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. If the maximum number of network security group rules is exceeded the request fails with HTTP status code 400.

Returns

A new BatchInboundNatPool instance for mocking.

Applies to