Microsoft.Network loadBalancers

Bicep 資源定義

loadBalancers 資源類型可以使用目標作業進行部署:

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄

資源格式

若要建立 Microsoft.Network/loadBalancers 資源,請將下列 Bicep 新增至範本。

resource symbolicname 'Microsoft.Network/loadBalancers@2023-04-01' = {
  name: 'string'
  location: 'string'
  tags: {
    tagName1: 'tagValue1'
    tagName2: 'tagValue2'
  }
  sku: {
    name: 'string'
    tier: 'string'
  }
  extendedLocation: {
    name: 'string'
    type: 'EdgeZone'
  }
  properties: {
    backendAddressPools: [
      {
        id: 'string'
        name: 'string'
        properties: {
          drainPeriodInSeconds: int
          loadBalancerBackendAddresses: [
            {
              name: 'string'
              properties: {
                adminState: 'string'
                ipAddress: 'string'
                loadBalancerFrontendIPConfiguration: {
                  id: 'string'
                }
                subnet: {
                  id: 'string'
                }
                virtualNetwork: {
                  id: 'string'
                }
              }
            }
          ]
          location: 'string'
          syncMode: 'string'
          tunnelInterfaces: [
            {
              identifier: int
              port: int
              protocol: 'string'
              type: 'string'
            }
          ]
          virtualNetwork: {
            id: 'string'
          }
        }
      }
    ]
    frontendIPConfigurations: [
      {
        id: 'string'
        name: 'string'
        properties: {
          gatewayLoadBalancer: {
            id: 'string'
          }
          privateIPAddress: 'string'
          privateIPAddressVersion: 'string'
          privateIPAllocationMethod: 'string'
          publicIPAddress: {
            extendedLocation: {
              name: 'string'
              type: 'EdgeZone'
            }
            id: 'string'
            location: 'string'
            properties: {
              ddosSettings: {
                ddosProtectionPlan: {
                  id: 'string'
                }
                protectionMode: 'string'
              }
              deleteOption: 'string'
              dnsSettings: {
                domainNameLabel: 'string'
                domainNameLabelScope: 'string'
                fqdn: 'string'
                reverseFqdn: 'string'
              }
              idleTimeoutInMinutes: int
              ipAddress: 'string'
              ipTags: [
                {
                  ipTagType: 'string'
                  tag: 'string'
                }
              ]
              linkedPublicIPAddress: {
                public-ip-address-object
              }
              migrationPhase: 'string'
              natGateway: {
                id: 'string'
                location: 'string'
                properties: {
                  idleTimeoutInMinutes: int
                  publicIpAddresses: [
                    {
                      id: 'string'
                    }
                  ]
                  publicIpPrefixes: [
                    {
                      id: 'string'
                    }
                  ]
                }
                sku: {
                  name: 'Standard'
                }
                tags: {}
                zones: [
                  'string'
                ]
              }
              publicIPAddressVersion: 'string'
              publicIPAllocationMethod: 'string'
              publicIPPrefix: {
                id: 'string'
              }
              servicePublicIPAddress: {
                public-ip-address-object
              }
            }
            sku: {
              name: 'string'
              tier: 'string'
            }
            tags: {}
            zones: [
              'string'
            ]
          }
          publicIPPrefix: {
            id: 'string'
          }
          subnet: {
            id: 'string'
            name: 'string'
            properties: {
              addressPrefix: 'string'
              addressPrefixes: [
                'string'
              ]
              applicationGatewayIPConfigurations: [
                {
                  id: 'string'
                  name: 'string'
                  properties: {
                    subnet: {
                      id: 'string'
                    }
                  }
                }
              ]
              delegations: [
                {
                  id: 'string'
                  name: 'string'
                  properties: {
                    serviceName: 'string'
                  }
                  type: 'string'
                }
              ]
              ipAllocations: [
                {
                  id: 'string'
                }
              ]
              natGateway: {
                id: 'string'
              }
              networkSecurityGroup: {
                id: 'string'
                location: 'string'
                properties: {
                  flushConnection: bool
                  securityRules: [
                    {
                      id: 'string'
                      name: 'string'
                      properties: {
                        access: 'string'
                        description: 'string'
                        destinationAddressPrefix: 'string'
                        destinationAddressPrefixes: [
                          'string'
                        ]
                        destinationApplicationSecurityGroups: [
                          {
                            id: 'string'
                            location: 'string'
                            properties: {}
                            tags: {}
                          }
                        ]
                        destinationPortRange: 'string'
                        destinationPortRanges: [
                          'string'
                        ]
                        direction: 'string'
                        priority: int
                        protocol: 'string'
                        sourceAddressPrefix: 'string'
                        sourceAddressPrefixes: [
                          'string'
                        ]
                        sourceApplicationSecurityGroups: [
                          {
                            id: 'string'
                            location: 'string'
                            properties: {}
                            tags: {}
                          }
                        ]
                        sourcePortRange: 'string'
                        sourcePortRanges: [
                          'string'
                        ]
                      }
                      type: 'string'
                    }
                  ]
                }
                tags: {}
              }
              privateEndpointNetworkPolicies: 'string'
              privateLinkServiceNetworkPolicies: 'string'
              routeTable: {
                id: 'string'
                location: 'string'
                properties: {
                  disableBgpRoutePropagation: bool
                  routes: [
                    {
                      id: 'string'
                      name: 'string'
                      properties: {
                        addressPrefix: 'string'
                        hasBgpOverride: bool
                        nextHopIpAddress: 'string'
                        nextHopType: 'string'
                      }
                      type: 'string'
                    }
                  ]
                }
                tags: {}
              }
              serviceEndpointPolicies: [
                {
                  id: 'string'
                  location: 'string'
                  properties: {
                    contextualServiceEndpointPolicies: [
                      'string'
                    ]
                    serviceAlias: 'string'
                    serviceEndpointPolicyDefinitions: [
                      {
                        id: 'string'
                        name: 'string'
                        properties: {
                          description: 'string'
                          service: 'string'
                          serviceResources: [
                            'string'
                          ]
                        }
                        type: 'string'
                      }
                    ]
                  }
                  tags: {}
                }
              ]
              serviceEndpoints: [
                {
                  locations: [
                    'string'
                  ]
                  service: 'string'
                }
              ]
            }
            type: 'string'
          }
        }
        zones: [
          'string'
        ]
      }
    ]
    inboundNatPools: [
      {
        id: 'string'
        name: 'string'
        properties: {
          backendPort: int
          enableFloatingIP: bool
          enableTcpReset: bool
          frontendIPConfiguration: {
            id: 'string'
          }
          frontendPortRangeEnd: int
          frontendPortRangeStart: int
          idleTimeoutInMinutes: int
          protocol: 'string'
        }
      }
    ]
    inboundNatRules: [
      {
        id: 'string'
        name: 'string'
        properties: {
          backendAddressPool: {
            id: 'string'
          }
          backendPort: int
          enableFloatingIP: bool
          enableTcpReset: bool
          frontendIPConfiguration: {
            id: 'string'
          }
          frontendPort: int
          frontendPortRangeEnd: int
          frontendPortRangeStart: int
          idleTimeoutInMinutes: int
          protocol: 'string'
        }
      }
    ]
    loadBalancingRules: [
      {
        id: 'string'
        name: 'string'
        properties: {
          backendAddressPool: {
            id: 'string'
          }
          backendAddressPools: [
            {
              id: 'string'
            }
          ]
          backendPort: int
          disableOutboundSnat: bool
          enableFloatingIP: bool
          enableTcpReset: bool
          frontendIPConfiguration: {
            id: 'string'
          }
          frontendPort: int
          idleTimeoutInMinutes: int
          loadDistribution: 'string'
          probe: {
            id: 'string'
          }
          protocol: 'string'
        }
      }
    ]
    outboundRules: [
      {
        id: 'string'
        name: 'string'
        properties: {
          allocatedOutboundPorts: int
          backendAddressPool: {
            id: 'string'
          }
          enableTcpReset: bool
          frontendIPConfigurations: [
            {
              id: 'string'
            }
          ]
          idleTimeoutInMinutes: int
          protocol: 'string'
        }
      }
    ]
    probes: [
      {
        id: 'string'
        name: 'string'
        properties: {
          intervalInSeconds: int
          numberOfProbes: int
          port: int
          probeThreshold: int
          protocol: 'string'
          requestPath: 'string'
        }
      }
    ]
  }
}

屬性值

loadBalancers

名稱 描述
NAME 資源名稱 字串 (必要)

字元限制:1-80

合法字元:
英數字元、底線、句號和連字號。

以英數字元開頭。 以英數字元或底線結尾。
location 資源位置。 字串
tags 資源標籤。 標記名稱和值的字典。 請參閱 範本中的標記
sku 負載平衡器 SKU。 LoadBalancerSku
extendedLocation 負載平衡器的擴充位置。 ExtendedLocation
properties 負載平衡器的屬性。 LoadBalancerPropertiesFormat

ExtendedLocation

名稱 描述
NAME 擴充位置的名稱。 字串
type 擴充位置的類型。 'EdgeZone'

LoadBalancerPropertiesFormat

名稱 描述
backendAddressPools 負載平衡器所使用的後端位址池集合。 BackendAddressPool[]
frontendIPConfigurations 物件,表示要用於負載平衡器的前端IP。 FrontendIPConfiguration[]
inboundNatPools 定義與負載平衡器相關聯之 NIC 上輸入 NAT 到單一後埠的外部埠範圍。 使用此範圍的外部埠,會自動為每個與 Load Balancer 相關聯的 NIC 建立輸入 NAT 規則。 在 Load Balancer 上定義輸入NAT集區,與定義輸入NAT規則互斥。 從虛擬機擴展集參考輸入NAT集區。 與個別虛擬機相關聯的 NIC 無法參考輸入 NAT 集區。 它們必須參考個別的輸入NAT規則。 InboundNatPool[]
inboundNatRules 負載平衡器所使用的輸入NAT規則集合。 在負載平衡器上定義輸入NAT規則與定義輸入NAT集區互斥。 從虛擬機擴展集參考輸入NAT集區。 與個別虛擬機相關聯的 NIC 無法參考輸入 NAT 集區。 它們必須參考個別的輸入NAT規則。 InboundNatRule[]
loadBalancingRules 代表負載平衡規則的物件集合 取得布建。 LoadBalancingRule[]
outboundRules 輸出規則。 OutboundRule[]
探查 負載平衡器中使用的探查物件集合。 探查[]

BackendAddressPool

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之後端位址池集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器後端位址池的屬性。 BackendAddressPoolPropertiesFormat

BackendAddressPoolPropertiesFormat

名稱 描述
drainPeriodInSeconds Load Balancer 將 RESET 傳送至用戶端和後端位址之前,等候的秒數。 int
loadBalancerBackendAddresses 後端位址的陣列。 LoadBalancerBackendAddress[]
location 後端位址池的位置。 字串
syncMode 後端集區的後端位址同步模式 'Automatic'
'Manual'
tunnelInterfaces 閘道連接平衡器通道介面的陣列。 GatewayLoadBalancerTunnelInterface[]
virtualNetwork 虛擬網路的參考。 SubResource

LoadBalancerBackendAddress

名稱 描述
NAME 後端位址的名稱。 字串
properties 負載平衡器後端位址池的屬性。 LoadBalancerBackendAddressPropertiesFormat

LoadBalancerBackendAddressPropertiesFormat

名稱 描述
adminState 系統管理狀態清單,一旦設定后可以覆寫健康情況探查,Load Balancer 一律會將新的連線轉送至後端,或拒絕新的連線並重設現有的連線。 'Down'
'None'
'Up'
ipAddress 屬於參考虛擬網路的IP位址。 字串
loadBalancerFrontendIPConfiguration 區域負載平衡器中定義的前端IP位址組態參考。 SubResource
子網路 現有子網的參考。 SubResource
virtualNetwork 現有虛擬網路的參考。 SubResource

SubResource

名稱 描述
id 資源識別碼。 字串

GatewayLoadBalancerTunnelInterface

名稱 描述
識別碼 (identifier) 閘道連接平衡器通道介面的識別碼。 int
連接埠 閘道連接平衡器通道介面的埠。 int
protocol 閘道連接平衡器通道介面的通訊協定。 'Native'
'None'
'VXLAN'
類型 閘道連接平衡器通道介面的流量類型。 'External'
'Internal'
'None'

FrontendIPConfiguration

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的一組前端IP組態內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器探查的屬性。 FrontendIPConfigurationPropertiesFormat
zones (區域) 可用性區域清單,指出為資源配置的IP需要來自。 string[]

FrontendIPConfigurationPropertiesFormat

名稱 描述
gatewayLoadBalancer 閘道負載平衡器前端IP的參考。 SubResource
privateIPAddress IP 組態的私人IP位址。 字串
privateIPAddressVersion 特定 ipconfiguration 是 IPv4 或 IPv6。 預設值會採用為 IPv4。 'IPv4'
'IPv6'
privateIPAllocationMethod 私人IP配置方法。 'Dynamic'
'Static'
publicIPAddress 公用IP資源的參考。 PublicIPAddress
publicIPPrefix 公用IP前置綴資源的參考。 SubResource
子網路 子網資源的參考。 子網路

PublicIPAddress

名稱 描述
extendedLocation 公用IP位址的擴充位置。 ExtendedLocation
id 資源識別碼。 字串
location 資源位置。 字串
properties 公用IP位址屬性。 PublicIPAddressPropertiesFormat
sku 公用IP位址 SKU。 PublicIPAddressSku
tags 資源標籤。 物件 (object)
zones (區域) 可用性區域清單,指出為資源配置的IP需要來自。 string[]

PublicIPAddressPropertiesFormat

名稱 描述
ddosSettings 與公用IP位址相關聯的 DDoS 保護自定義原則。 DdosSettings
deleteOption 指定刪除 VM 時,公用 IP 位址會發生什麼情況 'Delete'
'Detach'
dnsSettings 與公用IP位址相關聯的 DNS 記錄 FQDN。 PublicIPAddressDnsSettings
idleTimeoutInMinutes 公用IP位址的閒置逾時。 int
ipAddress 與公用IP位址資源相關聯的IP位址。 字串
ipTags 與公用IP位址相關聯的標記清單。 IpTag[]
linkedPublicIPAddress 公用IP位址資源的連結公用IP位址。 PublicIPAddress
migrationPhase 公用IP位址的移轉階段。 'Abort'
'Commit'
'Committed'
'None'
'Prepare'
natGateway 公用IP位址的 NatGateway。 NatGateway
publicIPAddressVersion 公用IP位址版本。 'IPv4'
'IPv6'
publicIPAllocationMethod 公用IP位址配置方法。 'Dynamic'
'Static'
publicIPPrefix 此公用 IP 位址的公用 IP 前置碼應該設定自 。 SubResource
servicePublicIPAddress 公用IP位址資源的服務公用IP位址。 PublicIPAddress

DdosSettings

名稱 描述
ddosProtectionPlan 與公用IP相關聯的 DDoS 保護計劃。 只有在 ProtectionMode 已啟用時,才能設定 SubResource
protectionMode 公用IP的 DDoS 保護模式 'Disabled'
'Enabled'
'VirtualNetworkInherited'

PublicIPAddressDnsSettings

名稱 描述
domainNameLabel 功能變數名稱標籤。 網域名稱標籤和已進行地區設定之 DNS 區域的串連可組成和公用 IP 位址相關聯的完整網域名稱。 如果已指定網域名稱標籤,則會在 Microsoft Azure DNS 系統中為公用 IP 建立 DNS 記錄。 字串
domainNameLabelScope 功能變數名稱標籤範圍。 如果指定功能變數名稱標籤和功能變數名稱標籤範圍,則會針對 Microsoft Azure DNS 系統中的公用 IP 建立 DNS 記錄,其中包含 FQDN 中的哈希值。 'NoReuse'
'ResourceGroupReuse'
'SubscriptionReuse'
'TenantReuse'
fqdn 與公用IP相關聯的 A DNS 記錄的完整功能變數名稱。 這是 domainNameLabel 和區域化 DNS 區域的串連。 字串
reverseFqdn 反向 FQDN。 可解析為這個公用IP位址的用戶可見完整功能變數名稱。 如果已指定 reverseFqdn,則會建立 PTR DNS 記錄,從 in-addr.arpa 網域中的 IP 位址指向反向 FQDN。 字串

IpTag

名稱 描述
ipTagType IP 標籤類型。 範例:FirstPartyUsage。 字串
標籤 與公用IP相關聯的IP標籤。 範例:SQL。 字串

NatGateway

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties Nat 閘道屬性。 NatGatewayPropertiesFormat
sku nat 閘道 SKU。 NatGatewaySku
tags 資源標籤。 物件 (object)
zones (區域) 可用性區域清單,指出應該在其中部署 Nat 閘道的區域。 string[]

NatGatewayPropertiesFormat

名稱 描述
idleTimeoutInMinutes nat 閘道的閒置逾時。 int
publicIpAddresses 與 nat 閘道資源相關聯的公用IP位址數位。 SubResource[]
publicIpPrefixes 與 nat 閘道資源相關聯的公用IP前置詞數位。 SubResource[]

NatGatewaySku

名稱 描述
NAME Nat 閘道 SKU 的名稱。 'Standard'

PublicIPAddressSku

名稱 描述
NAME 公用IP位址 SKU 的名稱。 'Basic'
'Standard'
tier 公用IP位址SKU的階層。 'Global'
'Regional'

子網路

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 子網的屬性。 SubnetPropertiesFormat
類型 資源類型。 字串

SubnetPropertiesFormat

名稱 描述
addressPrefix 子網的位址前置詞。 字串
addressPrefixes 子網的位址前置詞清單。 string[]
applicationGatewayIPConfigurations 虛擬網路資源的應用程式閘道IP組態。 ApplicationGatewayIPConfiguration[]
代表團 子網上委派的參考陣列。 委派[]
ipAllocations 參考此子網的 IpAllocation 陣列。 SubResource[]
natGateway 與此子網相關聯的 Nat 閘道。 SubResource
networkSecurityGroup NetworkSecurityGroup 資源的參考。 NetworkSecurityGroup
privateEndpointNetworkPolicies 在子網的私人端點上啟用或停用套用網路原則。 'Disabled'
'Enabled'
privateLinkServiceNetworkPolicies 在子網中的私人連結服務上啟用或停用套用網路原則。 'Disabled'
'Enabled'
routeTable RouteTable 資源的參考。 RouteTable
serviceEndpointPolicies 服務端點原則的陣列。 ServiceEndpointPolicy[]
serviceEndpoints 服務端點的陣列。 ServiceEndpointPropertiesFormat[]

ApplicationGatewayIPConfiguration

名稱 描述
id 資源識別碼。 字串
NAME 應用程式閘道 內唯一的IP組態名稱。 字串
properties 應用程式閘道IP組態的屬性。 ApplicationGatewayIPConfigurationPropertiesFormat

ApplicationGatewayIPConfigurationPropertiesFormat

名稱 描述
子網路 子網資源的參考。 應用程式閘道從中取得其私人位址的子網。 SubResource

委派

名稱 描述
id 資源識別碼。 字串
NAME 子網內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 子網的屬性。 ServiceDelegationPropertiesFormat
類型 資源類型。 字串

ServiceDelegationPropertiesFormat

名稱 描述
serviceName 子網應委派給的服務名稱 (,例如 Microsoft.Sql/servers) 。 字串

NetworkSecurityGroup

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 網路安全組的屬性。 NetworkSecurityGroupPropertiesFormat
tags 資源標籤。 物件 (object)

NetworkSecurityGroupPropertiesFormat

名稱 描述
flushConnection 啟用時,從網路安全組連線建立的流程會在更新規則時重新評估。 初始啟用將會觸發重新評估。 bool
securityRules 網路安全組的安全性規則集合。 SecurityRule[]

SecurityRule

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 安全性規則的屬性。 SecurityRulePropertiesFormat
類型 資源類型。 字串

SecurityRulePropertiesFormat

名稱 描述
access 允許或拒絕網路流量。 'Allow'
需要 『Deny』 ()
description 此規則的說明。 限制為140個字元。 字串
destinationAddressPrefix 目的地地址前綴。 CIDR 或目的地IP範圍。 也可用星號 (*) 來比對所有的來源 IP。 您也可以使用默認標籤,例如 'VirtualNetwork'、'AzureLoadBalancer' 和 'Internet'。 字串
destinationAddressPrefixes 目的地位址前置詞。 CIDR 或目的地IP範圍。 string[]
destinationApplicationSecurityGroups 指定為目的地的應用程式安全組。 ApplicationSecurityGroup[]
destinationPortRange 目的地埠或範圍。 介於 0 到 65535 之間的整數或範圍。 星號 『*』 也可以用來比對所有埠。 字串
destinationPortRanges 目的地埠範圍。 string[]
direction 規則的方向。 此方向指定是否根據連入或連出的流量評估規則。 'Inbound'
「輸出」 (必要)
priority 規則的優先順序。 此值可以介於 100 到 4096 之間。 集合中每個規則的優先順序數字必須是唯一的。 優先順序號碼愈小,規則優先順序就愈高。 需要 int ()
protocol 此規則適用的網路通訊協定。 '*'
'Ah'
'Esp'
'Icmp'
'Tcp'
必要 『Udp』 ()
sourceAddressPrefix CIDR 或來源IP範圍。 也可用星號 (*) 來比對所有的來源 IP。 您也可以使用默認標籤,例如 'VirtualNetwork'、'AzureLoadBalancer' 和 'Internet'。 如果這是輸入規則,請指定網路流量的來源。 字串
sourceAddressPrefixes CIDR 或來源IP範圍。 string[]
sourceApplicationSecurityGroups 指定為來源的應用程式安全組。 ApplicationSecurityGroup[]
sourcePortRange 來源埠或範圍。 介於 0 到 65535 之間的整數或範圍。 星號 『*』 也可以用來比對所有埠。 字串
sourcePortRanges 來源埠範圍。 string[]

ApplicationSecurityGroup

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 應用程式安全組的屬性。 ApplicationSecurityGroupPropertiesFormat
tags 資源標籤。 物件 (object)

ApplicationSecurityGroupPropertiesFormat

此物件不包含部署期間要設定的任何屬性。 所有屬性都是 ReadOnly。

RouteTable

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 路由表的屬性。 RouteTablePropertiesFormat
tags 資源標籤。 物件 (object)

RouteTablePropertiesFormat

名稱 描述
disableBgpRoutePropagation 是否要停用 BGP 在該路由表上學習的路由。 True 表示停用。 bool
路由 路由表中包含的路由集合。 Route[]

路由

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 路由的屬性。 RoutePropertiesFormat
類型 資源類型。 字串

RoutePropertiesFormat

名稱 描述
addressPrefix 路由套用的目標 CIDR。 字串
hasBgpOverride 值,指出不論 LPM 為何,此路由是否覆寫重疊的 BGP 路由。 bool
nextHopIpAddress IP 位址封包應轉送至 。 下一個躍點值只能在下一個躍點類型為 VirtualAppliance 的路由中允許。 字串
nextHopType 要接收封包的 Azure 躍點的類型。 'Internet'
'None'
'VirtualAppliance'
'VirtualNetworkGateway'
'VnetLocal' (必要)

ServiceEndpointPolicy

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 服務端點原則的屬性。 ServiceEndpointPolicyPropertiesFormat
tags 資源標籤。 物件 (object)

ServiceEndpointPolicyPropertiesFormat

名稱 描述
contextualServiceEndpointPolicies 內容服務端點原則的集合。 string[]
serviceAlias 指出原則是否屬於服務的別名 字串
serviceEndpointPolicyDefinitions 服務端點原則的服務端點原則定義集合。 ServiceEndpointPolicyDefinition[]

ServiceEndpointPolicyDefinition

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 服務端點原則定義的屬性。 ServiceEndpointPolicyDefinitionPropertiesFormat
類型 資源類型。 字串

ServiceEndpointPolicyDefinitionPropertiesFormat

名稱 描述
description 此規則的說明。 限制為140個字元。 字串
service 服務端點名稱。 字串
serviceResources 服務資源的清單。 string[]

ServiceEndpointPropertiesFormat

名稱 描述
位置 位置清單。 string[]
service 端點服務的型別。 字串

InboundNatPool

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之輸入NAT集區集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸入 nat 集區的屬性。 InboundNatPoolPropertiesFormat

InboundNatPoolPropertiesFormat

名稱 描述
backendPort 在端點上用於內部連接的連接埠。 可接受的值介於 1 到 65535 之間。 int (必要)
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPortRangeEnd 外部埠範圍中的最後一個埠號碼,用來將輸入 Nat 提供給與負載平衡器相關聯的 NIC。 可接受的值介於 1 到 65535 之間。 int (必要)
frontendPortRangeStart 外部埠範圍中的第一個埠號碼,用來將輸入 Nat 提供給與負載平衡器相關聯的 NIC。 可接受的值介於 1 到 65534 之間。 int (必要)
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
protocol 輸入 NAT 集區所使用的傳輸通訊協議參考。 'All'
'Tcp'
需要 『Udp』 ()

InboundNatRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之輸入NAT規則集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸入NAT規則的屬性。 InboundNatRulePropertiesFormat

InboundNatRulePropertiesFormat

名稱 描述
backendAddressPool backendAddressPool 資源的參考。 SubResource
backendPort 內部端點使用的連接埠。 可接受的值範圍從 1 到 65535。 int
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPort 外部端點的連接埠。 每個規則的埠號碼在 Load Balancer 內必須是唯一的。 可接受的值範圍從 1 到 65534。 int
frontendPortRangeEnd 外部端點的埠範圍結束。 此屬性會與 BackendAddressPool 和 FrontendPortRangeStart 搭配使用。 系統會為每個後端位址建立來自 BackendAddressPool 的個別輸入 NAT 規則埠對應。 可接受的值範圍從 1 到 65534。 int
frontendPortRangeStart 外部端點的埠範圍開始。 此屬性會與 BackendAddressPool 和 FrontendPortRangeEnd 搭配使用。 系統會為每個後端位址建立來自 BackendAddressPool 的個別輸入 NAT 規則埠對應。 可接受的值範圍從 1 到 65534。 int
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
protocol 負載平衡規則所使用的傳輸通訊協議參考。 'All'
'Tcp'
'Udp'

LoadBalancingRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之負載平衡規則集內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器負載平衡規則的屬性。 LoadBalancingRulePropertiesFormat

LoadBalancingRulePropertiesFormat

名稱 描述
backendAddressPool DIP 集區的參考。 輸入流量會在後端IP中的IP之間隨機負載平衡。 SubResource
backendAddressPools DIP 集區的參考陣列。 SubResource[]
backendPort 在端點上用於內部連接的連接埠。 可接受的值為 0 到 65535。 請注意,值 0 會啟用「任何埠」。 int
disableOutboundSnat 設定後端集區中 VM 的 SNAT,以使用負載平衡規則前端中指定的 publicIP 位址。 bool
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 在 SQL Server 中使用 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPort 外部端點的連接埠。 每個規則的埠號碼在 Load Balancer 內必須是唯一的。 可接受的值為 0 到 65534。 請注意,值 0 會啟用「任何埠」。 需要 int ()
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
loadDistribution 此規則的負載分配原則。 'Default'
'SourceIP'
'SourceIPProtocol'
探查 負載平衡規則所使用的負載平衡器探查參考。 SubResource
protocol 負載平衡規則所使用的傳輸通訊協議參考。 'All'
'Tcp'
必要 『Udp』 ()

OutboundRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用輸出規則集內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸出規則的屬性。 OutboundRulePropertiesFormat

OutboundRulePropertiesFormat

名稱 描述
allocatedOutboundPorts 要用於 NAT 的輸出埠數目。 int
backendAddressPool DIP 集區的參考。 輸出流量會在後端IP中的IP之間隨機負載平衡。 必要子資源 ()
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfigurations 負載平衡器的前端IP位址。 SubResource[] (必要)
idleTimeoutInMinutes TCP 閑置連線的逾時。 int
protocol 負載平衡器中輸出規則的通訊協定。 'All'
'Tcp'
需要 『Udp』 ()

探查

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的一組探查內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器探查的屬性。 ProbePropertiesFormat

ProbePropertiesFormat

名稱 描述
intervalInSeconds 探查端點健康情況狀態的頻率間隔 (以秒為單位)。 一般而言,間隔略小於配置逾時期間 (以秒為單位) 的一半,可允許在執行個體退出循環之前進行兩個完整探查。 預設值是 15,最小值是 5。 int
numberOfProbes 如果沒有回應,探查數目會導致進一步的流量無法傳遞至端點。 這個值可讓端點比 Azure 中使用的一般時間更快或慢,以更快速或慢的方式取用端點。 int
連接埠 用來與探查通訊的連接埠。 可能的值範圍從 1 到 65535 (含)。 int (必要)
probeThreshold 連續成功或失敗的探查數目,以允許或拒絕傳遞至此端點的流量。 失敗等於此值的連續探查數目之後,端點將會從輪替中取出,而且需要將相同的連續探查數目放在旋轉中。 int
protocol 端點的通訊協定。 如果指定了 『Tcp』,則需要接收的 ACK,才能成功探查。 如果指定 'Http' 或 'Https',則需要來自 指定 URI 的 200 OK 回應,探查才能成功。 'Http'
'Https'
必要的 『Tcp』 ()
requestPath 用來從 VM 要求健康情況狀態的 URI。 如果通訊協定設定為 HTTP,則需要路徑。 否則不允許。 沒有任何預設值。 字串

LoadBalancerSku

名稱 描述
NAME 負載平衡器 SKU 的名稱。 'Basic'
'Gateway'
'Standard'
tier 負載平衡器 SKU 的階層。 'Global'
'Regional'

快速入門範本

下列快速入門範本會部署此資源類型。

範本 描述
已鏈結至閘道 Load Balancer 的公用 Load Balancer

部署至 Azure
此範本可讓您部署鏈結至閘道 Load Balancer 的公用 Standard Load Balancer。 從因特網傳入的流量會透過linux VM (後端集區中的 NVA) 路由傳送至閘道 Load Balancer。
建立具有多個 NIC 和 RDP 可存取的 VM

部署至 Azure
此範本可讓您建立具有多個 (2 個) 網路介面的 虛擬機器, (NIC) ,以及使用已設定負載平衡器和輸入 NAT 規則連線的 RDP。 您可以使用此樣本輕鬆地新增更多 NIC。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址和2個網路介面, (前端和後端) 。
VNET 中的 2 部 VM - 內部 Load Balancer 和 LB 規則

部署至 Azure
此範本可讓您在 VNET 和內部負載平衡器下建立 2 個 虛擬機器,並在埠 80 上設定負載平衡規則。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址、可用性設定組和網路介面。
負載平衡器中的 2 部 VM 和負載平衡規則

部署至 Azure
此範本可讓您在負載平衡器下建立 2 虛擬機器,並在埠 80 上設定負載平衡規則。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址、可用性設定組和網路介面。 在此範本中,我們使用資源迴圈功能來建立網路介面和虛擬機
負載平衡器中的 2 部 VM,並在 LB 上設定 NAT 規則

部署至 Azure
此範本可讓您在可用性設定組中建立 2 虛擬機器,並透過負載平衡器設定 NAT 規則。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址和網路介面。 在此範本中,我們使用資源迴圈功能來建立網路介面和虛擬機
使用 ILB 後方的 Linux VM 部署 VM 擴展集

部署至 Azure
此範本可讓您使用最新修補的UbuntuLinux 15.10或14.04.4-4-LTS版本來部署Linux VM的 VM 擴展集。 這些 VM 位於內部負載平衡器後方,具有 SSH 連線的 NAT 規則。
適用於 VNetInjection 和 Load Balancer 的 AzureDatabricks 範本

部署至 Azure
此範本可讓您使用虛擬網路建立負載平衡器、網路安全組、虛擬網路和 Azure Databricks 工作區。
建立標準內部負載平衡器

部署至 Azure
此範本會使用規則負載平衡埠 80 建立標準內部 Azure Load Balancer
使用HA埠建立標準內部負載平衡器

部署至 Azure
此範本會使用HA埠負載平衡規則建立標準內部 Azure Load Balancer
建立跨區域負載平衡器

部署至 Azure
此範本會建立具有包含兩個區域負載平衡器的後端集區跨區域負載平衡器。 跨區域負載平衡器目前可在有限的區域中使用。 跨區域負載平衡器背後的區域負載平衡器可以位於任何區域中。
依IP位址 Standard Load Balancer後端集區

部署至 Azure
此範本可用來示範如何使用ARM樣本,依IP位址設定 Load Balancer的後端集區,如後端集區管理檔中所述。
建立具有公用 IPv6 位址的負載平衡器

部署至 Azure
此範本會建立因特網面向的負載平衡器,其中包含公用 IPv6 位址、負載平衡規則,以及後端集區的兩個 VM。
建立標準負載平衡器

部署至 Azure
此範本會為後端集區建立因特網面向的負載平衡器、負載平衡規則,以及三個 VM,且每個 VM 都位於備援區域中。
Load Balancer 具有 2 個 VIP,每個都有一個 LB 規則

部署至 Azure
此範本可讓您為負載平衡器建立 Load Balancer、2 個公用IP位址, (多重vip) 、虛擬網路、網路介面,虛擬網路 & 網路介面中網路介面,以及網路介面所使用的 Load Balancer。
使用輸入 NAT 規則 Load Balancer

部署至 Azure
此範本可讓您在網路介面所使用的 Load Balancer 中,為負載平衡器建立 Load Balancer、公用IP位址、虛擬網路、網路介面 虛擬網路 & NAT 規則。

ARM 範本資源定義

loadBalancers 資源類型可以使用目標作業進行部署:

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。

資源格式

若要建立 Microsoft.Network/loadBalancers 資源,請將下列 JSON 新增至範本。

{
  "type": "Microsoft.Network/loadBalancers",
  "apiVersion": "2023-04-01",
  "name": "string",
  "location": "string",
  "tags": {
    "tagName1": "tagValue1",
    "tagName2": "tagValue2"
  },
  "sku": {
    "name": "string",
    "tier": "string"
  },
  "extendedLocation": {
    "name": "string",
    "type": "EdgeZone"
  },
  "properties": {
    "backendAddressPools": [
      {
        "id": "string",
        "name": "string",
        "properties": {
          "drainPeriodInSeconds": "int",
          "loadBalancerBackendAddresses": [
            {
              "name": "string",
              "properties": {
                "adminState": "string",
                "ipAddress": "string",
                "loadBalancerFrontendIPConfiguration": {
                  "id": "string"
                },
                "subnet": {
                  "id": "string"
                },
                "virtualNetwork": {
                  "id": "string"
                }
              }
            }
          ],
          "location": "string",
          "syncMode": "string",
          "tunnelInterfaces": [
            {
              "identifier": "int",
              "port": "int",
              "protocol": "string",
              "type": "string"
            }
          ],
          "virtualNetwork": {
            "id": "string"
          }
        }
      }
    ],
    "frontendIPConfigurations": [
      {
        "id": "string",
        "name": "string",
        "properties": {
          "gatewayLoadBalancer": {
            "id": "string"
          },
          "privateIPAddress": "string",
          "privateIPAddressVersion": "string",
          "privateIPAllocationMethod": "string",
          "publicIPAddress": {
            "extendedLocation": {
              "name": "string",
              "type": "EdgeZone"
            },
            "id": "string",
            "location": "string",
            "properties": {
              "ddosSettings": {
                "ddosProtectionPlan": {
                  "id": "string"
                },
                "protectionMode": "string"
              },
              "deleteOption": "string",
              "dnsSettings": {
                "domainNameLabel": "string",
                "domainNameLabelScope": "string",
                "fqdn": "string",
                "reverseFqdn": "string"
              },
              "idleTimeoutInMinutes": "int",
              "ipAddress": "string",
              "ipTags": [
                {
                  "ipTagType": "string",
                  "tag": "string"
                }
              ],
              "linkedPublicIPAddress": { public-ip-address-object },
              "migrationPhase": "string",
              "natGateway": {
                "id": "string",
                "location": "string",
                "properties": {
                  "idleTimeoutInMinutes": "int",
                  "publicIpAddresses": [
                    {
                      "id": "string"
                    }
                  ],
                  "publicIpPrefixes": [
                    {
                      "id": "string"
                    }
                  ]
                },
                "sku": {
                  "name": "Standard"
                },
                "tags": {},
                "zones": [ "string" ]
              },
              "publicIPAddressVersion": "string",
              "publicIPAllocationMethod": "string",
              "publicIPPrefix": {
                "id": "string"
              },
              "servicePublicIPAddress": { public-ip-address-object }
            },
            "sku": {
              "name": "string",
              "tier": "string"
            },
            "tags": {},
            "zones": [ "string" ]
          },
          "publicIPPrefix": {
            "id": "string"
          },
          "subnet": {
            "id": "string",
            "name": "string",
            "properties": {
              "addressPrefix": "string",
              "addressPrefixes": [ "string" ],
              "applicationGatewayIPConfigurations": [
                {
                  "id": "string",
                  "name": "string",
                  "properties": {
                    "subnet": {
                      "id": "string"
                    }
                  }
                }
              ],
              "delegations": [
                {
                  "id": "string",
                  "name": "string",
                  "properties": {
                    "serviceName": "string"
                  },
                  "type": "string"
                }
              ],
              "ipAllocations": [
                {
                  "id": "string"
                }
              ],
              "natGateway": {
                "id": "string"
              },
              "networkSecurityGroup": {
                "id": "string",
                "location": "string",
                "properties": {
                  "flushConnection": "bool",
                  "securityRules": [
                    {
                      "id": "string",
                      "name": "string",
                      "properties": {
                        "access": "string",
                        "description": "string",
                        "destinationAddressPrefix": "string",
                        "destinationAddressPrefixes": [ "string" ],
                        "destinationApplicationSecurityGroups": [
                          {
                            "id": "string",
                            "location": "string",
                            "properties": {},
                            "tags": {}
                          }
                        ],
                        "destinationPortRange": "string",
                        "destinationPortRanges": [ "string" ],
                        "direction": "string",
                        "priority": "int",
                        "protocol": "string",
                        "sourceAddressPrefix": "string",
                        "sourceAddressPrefixes": [ "string" ],
                        "sourceApplicationSecurityGroups": [
                          {
                            "id": "string",
                            "location": "string",
                            "properties": {},
                            "tags": {}
                          }
                        ],
                        "sourcePortRange": "string",
                        "sourcePortRanges": [ "string" ]
                      },
                      "type": "string"
                    }
                  ]
                },
                "tags": {}
              },
              "privateEndpointNetworkPolicies": "string",
              "privateLinkServiceNetworkPolicies": "string",
              "routeTable": {
                "id": "string",
                "location": "string",
                "properties": {
                  "disableBgpRoutePropagation": "bool",
                  "routes": [
                    {
                      "id": "string",
                      "name": "string",
                      "properties": {
                        "addressPrefix": "string",
                        "hasBgpOverride": "bool",
                        "nextHopIpAddress": "string",
                        "nextHopType": "string"
                      },
                      "type": "string"
                    }
                  ]
                },
                "tags": {}
              },
              "serviceEndpointPolicies": [
                {
                  "id": "string",
                  "location": "string",
                  "properties": {
                    "contextualServiceEndpointPolicies": [ "string" ],
                    "serviceAlias": "string",
                    "serviceEndpointPolicyDefinitions": [
                      {
                        "id": "string",
                        "name": "string",
                        "properties": {
                          "description": "string",
                          "service": "string",
                          "serviceResources": [ "string" ]
                        },
                        "type": "string"
                      }
                    ]
                  },
                  "tags": {}
                }
              ],
              "serviceEndpoints": [
                {
                  "locations": [ "string" ],
                  "service": "string"
                }
              ]
            },
            "type": "string"
          }
        },
        "zones": [ "string" ]
      }
    ],
    "inboundNatPools": [
      {
        "id": "string",
        "name": "string",
        "properties": {
          "backendPort": "int",
          "enableFloatingIP": "bool",
          "enableTcpReset": "bool",
          "frontendIPConfiguration": {
            "id": "string"
          },
          "frontendPortRangeEnd": "int",
          "frontendPortRangeStart": "int",
          "idleTimeoutInMinutes": "int",
          "protocol": "string"
        }
      }
    ],
    "inboundNatRules": [
      {
        "id": "string",
        "name": "string",
        "properties": {
          "backendAddressPool": {
            "id": "string"
          },
          "backendPort": "int",
          "enableFloatingIP": "bool",
          "enableTcpReset": "bool",
          "frontendIPConfiguration": {
            "id": "string"
          },
          "frontendPort": "int",
          "frontendPortRangeEnd": "int",
          "frontendPortRangeStart": "int",
          "idleTimeoutInMinutes": "int",
          "protocol": "string"
        }
      }
    ],
    "loadBalancingRules": [
      {
        "id": "string",
        "name": "string",
        "properties": {
          "backendAddressPool": {
            "id": "string"
          },
          "backendAddressPools": [
            {
              "id": "string"
            }
          ],
          "backendPort": "int",
          "disableOutboundSnat": "bool",
          "enableFloatingIP": "bool",
          "enableTcpReset": "bool",
          "frontendIPConfiguration": {
            "id": "string"
          },
          "frontendPort": "int",
          "idleTimeoutInMinutes": "int",
          "loadDistribution": "string",
          "probe": {
            "id": "string"
          },
          "protocol": "string"
        }
      }
    ],
    "outboundRules": [
      {
        "id": "string",
        "name": "string",
        "properties": {
          "allocatedOutboundPorts": "int",
          "backendAddressPool": {
            "id": "string"
          },
          "enableTcpReset": "bool",
          "frontendIPConfigurations": [
            {
              "id": "string"
            }
          ],
          "idleTimeoutInMinutes": "int",
          "protocol": "string"
        }
      }
    ],
    "probes": [
      {
        "id": "string",
        "name": "string",
        "properties": {
          "intervalInSeconds": "int",
          "numberOfProbes": "int",
          "port": "int",
          "probeThreshold": "int",
          "protocol": "string",
          "requestPath": "string"
        }
      }
    ]
  }
}

屬性值

loadBalancers

名稱 描述
類型 資源類型 'Microsoft.Network/loadBalancers'
apiVersion 資源 API 版本 '2023-04-01'
NAME 資源名稱 需要字串 ()

字元限制:1-80

合法字元:
英數字元、底線、句號和連字號。

以英數字元開頭。 以英數字元或底線結尾。
location 資源位置。 字串
tags 資源標籤。 標記名稱和值的字典。 請參閱 範本中的標籤
sku 負載平衡器 SKU。 LoadBalancerSku
extendedLocation 負載平衡器的擴充位置。 ExtendedLocation
properties 負載平衡器的屬性。 LoadBalancerPropertiesFormat

ExtendedLocation

名稱 描述
NAME 擴充位置的名稱。 字串
type 擴充位置的類型。 'EdgeZone'

LoadBalancerPropertiesFormat

名稱 描述
backendAddressPools 負載平衡器所使用的後端位址池集合。 BackendAddressPool[]
frontendIPConfigurations 物件,表示要用於負載平衡器的前端IP。 FrontendIPConfiguration[]
inboundNatPools 定義與負載平衡器相關聯之 NIC 上單一後埠之輸入 NAT 的外部埠範圍。 輸入 NAT 規則會自動針對使用此範圍的外部埠,針對與 Load Balancer 相關聯的每個 NIC 建立。 在 Load Balancer 上定義輸入NAT集區,與定義輸入NAT規則互斥。 輸入 NAT 集區是從虛擬機擴展集參考。 與個別虛擬機相關聯的 NIC 無法參考輸入 NAT 集區。 它們必須參考個別的輸入NAT規則。 InboundNatPool[]
inboundNatRules 負載平衡器所使用的輸入NAT規則集合。 在負載平衡器上定義輸入NAT規則與定義輸入NAT集區互斥。 輸入 NAT 集區是從虛擬機擴展集參考。 與個別虛擬機相關聯的 NIC 無法參考輸入 NAT 集區。 它們必須參考個別的輸入NAT規則。 InboundNatRule[]
loadBalancingRules 物件集合,表示負載平衡規則 取得布建。 LoadBalancingRule[]
outboundRules 輸出規則。 OutboundRule[]
探查 負載平衡器中使用的探查物件集合。 Probe[]

BackendAddressPool

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之後端位址池集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器後端位址池的屬性。 BackendAddressPoolPropertiesFormat

BackendAddressPoolPropertiesFormat

名稱 描述
drainPeriodInSeconds Load Balancer 將 RESET 傳送至用戶端和後端位址之前,等候的秒數。 int
loadBalancerBackendAddresses 後端位址的陣列。 LoadBalancerBackendAddress[]
location 後端位址池的位置。 字串
syncMode 後端集區的後端位址同步模式 'Automatic'
'Manual'
tunnelInterfaces 閘道連接平衡器通道介面的陣列。 GatewayLoadBalancerTunnelInterface[]
virtualNetwork 虛擬網路的參考。 SubResource

LoadBalancerBackendAddress

名稱 描述
NAME 後端位址的名稱。 字串
properties 負載平衡器後端位址池的屬性。 LoadBalancerBackendAddressPropertiesFormat

LoadBalancerBackendAddressPropertiesFormat

名稱 描述
adminState 系統管理狀態清單,一旦設定后可以覆寫健康情況探查,Load Balancer 一律會將新的連線轉送至後端,或拒絕新的連線並重設現有的連線。 'Down'
'None'
'Up'
ipAddress 屬於參考虛擬網路的IP位址。 字串
loadBalancerFrontendIPConfiguration 區域負載平衡器中定義的前端IP位址組態參考。 SubResource
子網路 現有子網的參考。 SubResource
virtualNetwork 現有虛擬網路的參考。 SubResource

SubResource

名稱 描述
id 資源識別碼。 字串

GatewayLoadBalancerTunnelInterface

名稱 描述
識別碼 (identifier) 閘道連接平衡器通道介面的識別碼。 int
連接埠 閘道連接平衡器通道介面的埠。 int
protocol 閘道連接平衡器通道介面的通訊協定。 'Native'
'None'
'VXLAN'
類型 閘道連接平衡器通道介面的流量類型。 'External'
'Internal'
'None'

FrontendIPConfiguration

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的前端IP組態集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器探查的屬性。 FrontendIPConfigurationPropertiesFormat
zones (區域) 可用性區域清單,指出為資源配置的IP必須來自。 string[]

FrontendIPConfigurationPropertiesFormat

名稱 描述
gatewayLoadBalancer 閘道負載平衡器前端IP的參考。 SubResource
privateIPAddress IP 組態的私人IP位址。 字串
privateIPAddressVersion 特定 ipconfiguration 是 IPv4 或 IPv6。 預設值會視為 IPv4。 'IPv4'
'IPv6'
privateIPAllocationMethod 私人IP配置方法。 'Dynamic'
'Static'
publicIPAddress 公用IP資源的參考。 PublicIPAddress
publicIPPrefix 公用IP前置詞資源的參考。 SubResource
子網路 子網資源的參考。 子網路

PublicIPAddress

名稱 描述
extendedLocation 公用IP位址的擴充位置。 ExtendedLocation
id 資源識別碼。 字串
location 資源位置。 字串
properties 公用IP位址屬性。 PublicIPAddressPropertiesFormat
sku 公用IP位址 SKU。 PublicIPAddressSku
tags 資源標籤。 物件 (object)
zones (區域) 可用性區域清單,指出為資源配置的IP必須來自。 string[]

PublicIPAddressPropertiesFormat

名稱 描述
ddosSettings 與公用IP位址相關聯的 DDoS 保護自定義原則。 DdosSettings
deleteOption 指定刪除 VM 時,公用 IP 位址會發生什麼情況 'Delete'
'Detach'
dnsSettings 與公用IP位址相關聯的 DNS 記錄 FQDN。 PublicIPAddressDnsSettings
idleTimeoutInMinutes 公用IP位址的閒置逾時。 int
ipAddress 與公用IP位址資源相關聯的IP位址。 字串
ipTags 與公用IP位址相關聯的標記清單。 IpTag[]
linkedPublicIPAddress 公用IP位址資源的連結公用IP位址。 PublicIPAddress
migrationPhase 公用IP位址的移轉階段。 'Abort'
'Commit'
'Committed'
'None'
'Prepare'
natGateway 公用IP位址的 NatGateway。 NatGateway
publicIPAddressVersion 公用IP位址版本。 'IPv4'
'IPv6'
publicIPAllocationMethod 公用IP位址配置方法。 'Dynamic'
'Static'
publicIPPrefix 應該配置此公用IP位址的公用IP前置綴。 SubResource
servicePublicIPAddress 公用IP位址資源的服務公用IP位址。 PublicIPAddress

DdosSettings

名稱 描述
ddosProtectionPlan 與公用IP相關聯的 DDoS 保護計劃。 只有在 ProtectionMode 為 Enabled 時才能設定 SubResource
protectionMode 公用IP的 DDoS 保護模式 'Disabled'
'Enabled'
'VirtualNetworkInherited'

PublicIPAddressDnsSettings

名稱 描述
domainNameLabel 功能變數名稱標籤。 網域名稱標籤和已進行地區設定之 DNS 區域的串連可組成和公用 IP 位址相關聯的完整網域名稱。 如果已指定網域名稱標籤,則會在 Microsoft Azure DNS 系統中為公用 IP 建立 DNS 記錄。 字串
domainNameLabelScope 功能變數名稱標籤範圍。 如果指定功能變數名稱標籤和功能變數名稱標籤範圍,則會為 Microsoft Azure DNS 系統中的公用 IP 建立 A DNS 記錄,其中包含 FQDN 中的哈希值。 'NoReuse'
'ResourceGroupReuse'
'SubscriptionReuse'
'TenantReuse'
fqdn 與公用IP相關聯之 A DNS 記錄的完整功能變數名稱。 這是 domainNameLabel 和區域化 DNS 區域的串連。 字串
reverseFqdn 反向 FQDN。 可解析為此公用IP位址的用戶可見完整功能變數名稱。 如果已指定 reverseFqdn,則會建立 PTR DNS 記錄,從 in-addr.arpa 網域中的 IP 位址指向反向 FQDN。 字串

IpTag

名稱 描述
ipTagType IP 標籤類型。 範例:FirstPartyUsage。 字串
標籤 與公用IP相關聯的IP標籤。 範例:SQL。 字串

NatGateway

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties Nat 閘道屬性。 NatGatewayPropertiesFormat
sku nat 閘道 SKU。 NatGatewaySku
tags 資源標籤。 物件 (object)
zones (區域) 可用性區域清單,指出應該在其中部署 Nat 閘道的區域。 string[]

NatGatewayPropertiesFormat

名稱 描述
idleTimeoutInMinutes nat 閘道的閒置逾時。 int
publicIpAddresses 與 nat 閘道資源相關聯的公用IP位址數位。 SubResource[]
publicIpPrefixes 與 nat 閘道資源相關聯的公用IP前置詞數位。 SubResource[]

NatGatewaySku

名稱 描述
NAME Nat 閘道 SKU 的名稱。 'Standard'

PublicIPAddressSku

名稱 描述
NAME 公用IP位址 SKU 的名稱。 'Basic'
'Standard'
tier 公用IP位址SKU的階層。 'Global'
'Regional'

子網路

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 子網的屬性。 SubnetPropertiesFormat
類型 資源類型。 字串

SubnetPropertiesFormat

名稱 描述
addressPrefix 子網的位址前置詞。 字串
addressPrefixes 子網的位址前置詞清單。 string[]
applicationGatewayIPConfigurations 虛擬網路資源的應用程式閘道IP組態。 ApplicationGatewayIPConfiguration[]
代表團 子網上委派的參考陣列。 委派[]
ipAllocations 參考此子網的 IpAllocation 陣列。 SubResource[]
natGateway 與此子網相關聯的 Nat 閘道。 SubResource
networkSecurityGroup NetworkSecurityGroup 資源的參考。 NetworkSecurityGroup
privateEndpointNetworkPolicies 在子網的私人端點上啟用或停用套用網路原則。 'Disabled'
'Enabled'
privateLinkServiceNetworkPolicies 在子網中的私人連結服務上啟用或停用套用網路原則。 'Disabled'
'Enabled'
routeTable RouteTable 資源的參考。 RouteTable
serviceEndpointPolicies 服務端點原則的陣列。 ServiceEndpointPolicy[]
serviceEndpoints 服務端點的陣列。 ServiceEndpointPropertiesFormat[]

ApplicationGatewayIPConfiguration

名稱 描述
id 資源識別碼。 字串
NAME 應用程式閘道 內唯一的IP組態名稱。 字串
properties 應用程式閘道IP組態的屬性。 ApplicationGatewayIPConfigurationPropertiesFormat

ApplicationGatewayIPConfigurationPropertiesFormat

名稱 描述
子網路 子網資源的參考。 應用程式閘道從其中取得其私人位址的子網。 SubResource

委派

名稱 描述
id 資源識別碼。 字串
NAME 子網內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 子網的屬性。 ServiceDelegationPropertiesFormat
類型 資源類型。 字串

ServiceDelegationPropertiesFormat

名稱 描述
serviceName 子網應委派給的服務名稱 (例如 Microsoft.Sql/servers) 。 字串

NetworkSecurityGroup

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 網路安全組的屬性。 NetworkSecurityGroupPropertiesFormat
tags 資源標籤。 物件 (object)

NetworkSecurityGroupPropertiesFormat

名稱 描述
flushConnection 啟用時,從網路安全組連線建立的流程會在更新規則時重新評估。 初始啟用將會觸發重新評估。 bool
securityRules 網路安全組的安全性規則集合。 SecurityRule[]

SecurityRule

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 安全性規則的屬性。 SecurityRulePropertiesFormat
類型 資源類型。 字串

SecurityRulePropertiesFormat

名稱 描述
access 允許或拒絕網路流量。 'Allow'
必要) ('Deny'
description 此規則的說明。 限制為140個字元。 字串
destinationAddressPrefix 目的地位址前置詞。 CIDR 或目的地IP範圍。 也可用星號 (*) 來比對所有的來源 IP。 您也可以使用默認標籤,例如 'VirtualNetwork'、'AzureLoadBalancer' 和 'Internet'。 字串
destinationAddressPrefixes 目的地位址前置詞。 CIDR 或目的地IP範圍。 string[]
destinationApplicationSecurityGroups 指定為目的地的應用程式安全組。 ApplicationSecurityGroup[]
destinationPortRange 目的地埠或範圍。 介於 0 到 65535 之間的整數或範圍。 星號 『*』 也可以用來比對所有埠。 字串
destinationPortRanges 目的地埠範圍。 string[]
direction 規則的方向。 此方向指定是否根據連入或連出的流量評估規則。 'Inbound'
必要的「輸出」 ()
priority 規則的優先順序。 此值可以介於 100 到 4096 之間。 集合中每個規則的優先順序數字必須是唯一的。 優先順序號碼愈小,規則優先順序就愈高。 int (必要)
protocol 此規則適用的網路通訊協定。 '*'
'Ah'
'Esp'
'Icmp'
'Tcp'
需要 『Udp』 ()
sourceAddressPrefix CIDR 或來源IP範圍。 也可用星號 (*) 來比對所有的來源 IP。 您也可以使用默認標籤,例如 'VirtualNetwork'、'AzureLoadBalancer' 和 'Internet'。 如果這是輸入規則,請指定網路流量的來源。 字串
sourceAddressPrefixes CIDR 或來源IP範圍。 string[]
sourceApplicationSecurityGroups 指定為來源的應用程式安全組。 ApplicationSecurityGroup[]
sourcePortRange 來源埠或範圍。 介於 0 到 65535 之間的整數或範圍。 星號 『*』 也可以用來比對所有埠。 字串
sourcePortRanges 來源埠範圍。 string[]

ApplicationSecurityGroup

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 應用程式安全組的屬性。 ApplicationSecurityGroupPropertiesFormat
tags 資源標籤。 物件 (object)

ApplicationSecurityGroupPropertiesFormat

此物件不包含部署期間要設定的任何屬性。 所有屬性都是 ReadOnly。

RouteTable

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 路由表的屬性。 RouteTablePropertiesFormat
tags 資源標籤。 物件 (object)

RouteTablePropertiesFormat

名稱 描述
disableBgpRoutePropagation 是否要停用 BGP 在該路由表上學習的路由。 True 表示停用。 bool
路由 路由表中包含的路由集合。 Route[]

路由

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 路由的屬性。 RoutePropertiesFormat
類型 資源類型。 字串

RoutePropertiesFormat

名稱 描述
addressPrefix 路由套用的目標 CIDR。 字串
hasBgpOverride 值,指出不論 LPM 為何,此路由是否覆寫重疊的 BGP 路由。 bool
nextHopIpAddress IP 位址封包應轉送至 。 只有在下一個躍點類型為 VirtualAppliance 的路由中,才允許下一個躍點值。 字串
nextHopType 要接收封包的 Azure 躍點的類型。 'Internet'
'None'
'VirtualAppliance'
'VirtualNetworkGateway'
'VnetLocal' (必要)

ServiceEndpointPolicy

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 服務端點原則的屬性。 ServiceEndpointPolicyPropertiesFormat
tags 資源標籤。 物件 (object)

ServiceEndpointPolicyPropertiesFormat

名稱 描述
contextualServiceEndpointPolicies 關係型服務端點原則的集合。 string[]
serviceAlias 別名,指出原則是否屬於服務 字串
serviceEndpointPolicyDefinitions 服務端點原則的服務端點原則定義集合。 ServiceEndpointPolicyDefinition[]

ServiceEndpointPolicyDefinition

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 服務端點原則定義的屬性。 ServiceEndpointPolicyDefinitionPropertiesFormat
類型 資源類型。 字串

ServiceEndpointPolicyDefinitionPropertiesFormat

名稱 描述
description 此規則的說明。 限制為140個字元。 字串
service 服務端點名稱。 字串
serviceResources 服務資源的清單。 string[]

ServiceEndpointPropertiesFormat

名稱 描述
位置 位置清單。 string[]
service 端點服務的型別。 字串

InboundNatPool

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之輸入NAT集區集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸入 nat 集區的屬性。 InboundNatPoolPropertiesFormat

InboundNatPoolPropertiesFormat

名稱 描述
backendPort 在端點上用於內部連接的連接埠。 可接受的值介於 1 到 65535 之間。 int (必要)
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPortRangeEnd 外部埠範圍中的最後一個埠號碼,用來將輸入 Nat 提供給與負載平衡器相關聯的 NIC。 可接受的值介於 1 到 65535 之間。 int (必要)
frontendPortRangeStart 外部埠範圍中的第一個埠號碼,用來將輸入 Nat 提供給與負載平衡器相關聯的 NIC。 可接受的值介於 1 到 65534 之間。 int (必要)
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
protocol 輸入 NAT 集區所使用的傳輸通訊協議參考。 'All'
'Tcp'
需要 『Udp』 ()

InboundNatRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之輸入NAT規則集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸入NAT規則的屬性。 InboundNatRulePropertiesFormat

InboundNatRulePropertiesFormat

名稱 描述
backendAddressPool backendAddressPool 資源的參考。 SubResource
backendPort 內部端點使用的連接埠。 可接受的值範圍從 1 到 65535。 int
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPort 外部端點的連接埠。 每個規則的埠號碼在 Load Balancer 內必須是唯一的。 可接受的值範圍從 1 到 65534。 int
frontendPortRangeEnd 外部端點的埠範圍結束。 此屬性會與 BackendAddressPool 和 FrontendPortRangeStart 搭配使用。 系統會為每個後端位址建立來自 BackendAddressPool 的個別輸入 NAT 規則埠對應。 可接受的值範圍從 1 到 65534。 int
frontendPortRangeStart 外部端點的埠範圍開始。 此屬性會與 BackendAddressPool 和 FrontendPortRangeEnd 搭配使用。 系統會為每個後端位址建立來自 BackendAddressPool 的個別輸入 NAT 規則埠對應。 可接受的值範圍從 1 到 65534。 int
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
protocol 負載平衡規則所使用的傳輸通訊協議參考。 'All'
'Tcp'
'Udp'

LoadBalancingRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的負載平衡規則集內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器負載平衡規則的屬性。 LoadBalancingRulePropertiesFormat

LoadBalancingRulePropertiesFormat

名稱 描述
backendAddressPool DIP 集區的參考。 輸入流量會在後端IP中的IP之間隨機負載平衡。 SubResource
backendAddressPools DIP 集區的參考陣列。 SubResource[]
backendPort 在端點上用於內部連接的連接埠。 可接受的值為 0 到 65535。 請注意,值 0 會啟用「任何埠」。 int
disableOutboundSnat 設定後端集區中 VM 的 SNAT,以使用負載平衡規則前端中指定的 publicIP 位址。 bool
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPort 外部端點的連接埠。 每個規則的埠號碼在 Load Balancer 內必須是唯一的。 可接受的值介於 0 到 65534 之間。 請注意,值 0 會啟用「任何埠」。 int (必要)
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
loadDistribution 此規則的負載分配原則。 'Default'
'SourceIP'
'SourceIPProtocol'
探查 負載平衡規則所使用的負載平衡器探查參考。 SubResource
protocol 負載平衡規則所使用的傳輸通訊協議參考。 'All'
'Tcp'
需要 『Udp』 ()

OutboundRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的輸出規則集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸出規則的屬性。 OutboundRulePropertiesFormat

OutboundRulePropertiesFormat

名稱 描述
allocatedOutboundPorts 要用於 NAT 的輸出埠數目。 int
backendAddressPool DIP 集區的參考。 輸出流量會在後端IP中的IP之間隨機負載平衡。 必要子資源 ()
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfigurations 負載平衡器的前端IP位址。 SubResource[] (必要)
idleTimeoutInMinutes TCP 閑置連線的逾時。 int
protocol 負載平衡器中輸出規則的通訊協定。 'All'
'Tcp'
需要 『Udp』 ()

探查

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的一組探查內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器探查的屬性。 ProbePropertiesFormat

ProbePropertiesFormat

名稱 描述
intervalInSeconds 探查端點健康情況狀態的頻率間隔 (以秒為單位)。 一般而言,間隔略小於配置逾時期間 (以秒為單位) 的一半,可允許在執行個體退出循環之前進行兩個完整探查。 預設值是 15,最小值是 5。 int
numberOfProbes 如果沒有回應,探查數目會導致進一步的流量無法傳遞至端點。 這個值可讓端點比 Azure 中使用的一般時間更快或慢,以更快速或慢的方式取用端點。 int
連接埠 用來與探查通訊的連接埠。 可能的值範圍從 1 到 65535 (含)。 int (必要)
probeThreshold 連續成功或失敗的探查數目,以允許或拒絕傳遞至此端點的流量。 失敗等於此值的連續探查數目之後,端點將會從輪替中取出,而且需要將相同的連續探查數目放在旋轉中。 int
protocol 端點的通訊協定。 如果指定了 『Tcp』,則需要接收的 ACK,才能成功探查。 如果指定 'Http' 或 'Https',則需要來自 指定 URI 的 200 OK 回應,探查才能成功。 'Http'
'Https'
必要的 『Tcp』 ()
requestPath 用來從 VM 要求健康情況狀態的 URI。 如果通訊協定設定為 HTTP,則需要路徑。 否則不允許。 沒有任何預設值。 字串

LoadBalancerSku

名稱 描述
NAME 負載平衡器 SKU 的名稱。 'Basic'
'Gateway'
'Standard'
tier 負載平衡器 SKU 的階層。 'Global'
'Regional'

快速入門範本

下列快速入門範本會部署此資源類型。

範本 描述
已鏈結至閘道 Load Balancer 的公用 Load Balancer

部署至 Azure
此範本可讓您部署鏈結至閘道 Load Balancer 的公用 Standard Load Balancer。 從因特網傳入的流量會透過linux VM (後端集區中的 NVA) 路由傳送至閘道 Load Balancer。
建立具有多個 NIC 和 RDP 可存取的 VM

部署至 Azure
此範本可讓您建立具有多個 (2) 網路介面的 虛擬機器, (NIC) ,以及使用已設定的負載平衡器和輸入 NAT 規則連線的 RDP。 您可以使用此樣本輕鬆地新增更多 NIC。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址和2個網路介面, (前端和後端) 。
VNET 中的 2 部 VM - 內部 Load Balancer 和 LB 規則

部署至 Azure
此範本可讓您在 VNET 和內部負載平衡器下建立 2 個 虛擬機器,並在埠 80 上設定負載平衡規則。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址、可用性設定組和網路介面。
負載平衡器中的 2 部 VM 和負載平衡規則

部署至 Azure
此範本可讓您在負載平衡器下建立 2 個 虛擬機器,並在埠 80 上設定負載平衡規則。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址、可用性設定組和網路介面。 在此範本中,我們使用資源迴圈功能來建立網路介面和虛擬機
負載平衡器中的 2 部 VM,並在 LB 上設定 NAT 規則

部署至 Azure
此範本可讓您在可用性設定組中建立 2 個 虛擬機器,並透過負載平衡器設定 NAT 規則。 此範本也會部署記憶體帳戶、虛擬網路、公用IP位址和網路介面。 在此範本中,我們使用資源迴圈功能來建立網路介面和虛擬機
在 ILB 後方部署具有 Linux VM 的 VM 擴展集

部署至 Azure
此範本可讓您使用最新修補版本的 Ubuntu Linux 15.10 或 14.04.4-LTS 來部署 Linux VM 的 VM 擴展集。 這些 VM 位於內部負載平衡器後方,具有 SSH 連線的 NAT 規則。
適用於 VNetInjection 和 Load Balancer 的 AzureDatabricks 範本

部署至 Azure
此範本可讓您使用虛擬網路建立負載平衡器、網路安全組、虛擬網路和 Azure Databricks 工作區。
建立標準內部負載平衡器

部署至 Azure
此範本會建立具有規則負載平衡埠 80 的標準內部 Azure Load Balancer
使用HA埠建立標準內部負載平衡器

部署至 Azure
此範本會建立具有HA埠負載平衡規則的標準內部 Azure Load Balancer
建立跨區域負載平衡器

部署至 Azure
此範本會建立具有包含兩個區域負載平衡器的後端集區跨區域負載平衡器。 跨區域負載平衡器目前可在有限的區域中使用。 跨區域負載平衡器背後的區域負載平衡器可以位於任何區域中。
依IP位址使用後端集區 Standard Load Balancer

部署至 Azure
此範本是用來示範如何使用ARM樣本,依IP位址設定 Load Balancer的後端集區,如後端集區管理檔中所述。
建立具有公用 IPv6 位址的負載平衡器

部署至 Azure
此範本會建立因特網面向的負載平衡器,其中包含公用 IPv6 位址、負載平衡規則,以及後端集區的兩部 VM。
建立標準負載平衡器

部署至 Azure
此範本會為後端集區建立因特網面向的負載平衡器、負載平衡規則和三個 VM,並在備援區域中具有每個 VM。
Load Balancer 具有 2 個 VIP,每一個都有一個 LB 規則

部署至 Azure
此範本可讓您為負載平衡器建立 Load Balancer、2 個公用IP位址, (多重vip) 、虛擬網路、網路介面,虛擬網路 &網路介面所使用之 Load Balancer的 LB 規則。
使用輸入 NAT 規則 Load Balancer

部署至 Azure
此範本可讓您為負載平衡器建立 Load Balancer、公用IP位址、虛擬網路、網路介面,虛擬網路 &網路介面所使用的 Load Balancer NAT 規則。

Terraform (AzAPI 提供者) 資源定義

loadBalancers 資源類型可以使用目標作業進行部署:

  • 資源群組

如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄

資源格式

若要建立 Microsoft.Network/loadBalancers 資源,請將下列 Terraform 新增至您的範本。

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.Network/loadBalancers@2023-04-01"
  name = "string"
  location = "string"
  parent_id = "string"
  tags = {
    tagName1 = "tagValue1"
    tagName2 = "tagValue2"
  }
  body = jsonencode({
    properties = {
      backendAddressPools = [
        {
          id = "string"
          name = "string"
          properties = {
            drainPeriodInSeconds = int
            loadBalancerBackendAddresses = [
              {
                name = "string"
                properties = {
                  adminState = "string"
                  ipAddress = "string"
                  loadBalancerFrontendIPConfiguration = {
                    id = "string"
                  }
                  subnet = {
                    id = "string"
                  }
                  virtualNetwork = {
                    id = "string"
                  }
                }
              }
            ]
            location = "string"
            syncMode = "string"
            tunnelInterfaces = [
              {
                identifier = int
                port = int
                protocol = "string"
                type = "string"
              }
            ]
            virtualNetwork = {
              id = "string"
            }
          }
        }
      ]
      frontendIPConfigurations = [
        {
          id = "string"
          name = "string"
          properties = {
            gatewayLoadBalancer = {
              id = "string"
            }
            privateIPAddress = "string"
            privateIPAddressVersion = "string"
            privateIPAllocationMethod = "string"
            publicIPAddress = {
              extendedLocation = {
                name = "string"
                type = "EdgeZone"
              }
              id = "string"
              location = "string"
              properties = {
                ddosSettings = {
                  ddosProtectionPlan = {
                    id = "string"
                  }
                  protectionMode = "string"
                }
                deleteOption = "string"
                dnsSettings = {
                  domainNameLabel = "string"
                  domainNameLabelScope = "string"
                  fqdn = "string"
                  reverseFqdn = "string"
                }
                idleTimeoutInMinutes = int
                ipAddress = "string"
                ipTags = [
                  {
                    ipTagType = "string"
                    tag = "string"
                  }
                ]
                linkedPublicIPAddress = {
                  public-ip-address-object
                }
                migrationPhase = "string"
                natGateway = {
                  id = "string"
                  location = "string"
                  properties = {
                    idleTimeoutInMinutes = int
                    publicIpAddresses = [
                      {
                        id = "string"
                      }
                    ]
                    publicIpPrefixes = [
                      {
                        id = "string"
                      }
                    ]
                  }
                  sku = {
                    name = "Standard"
                  }
                  tags = {}
                  zones = [
                    "string"
                  ]
                }
                publicIPAddressVersion = "string"
                publicIPAllocationMethod = "string"
                publicIPPrefix = {
                  id = "string"
                }
                servicePublicIPAddress = {
                  public-ip-address-object
                }
              }
              sku = {
                name = "string"
                tier = "string"
              }
              tags = {}
              zones = [
                "string"
              ]
            }
            publicIPPrefix = {
              id = "string"
            }
            subnet = {
              id = "string"
              name = "string"
              properties = {
                addressPrefix = "string"
                addressPrefixes = [
                  "string"
                ]
                applicationGatewayIPConfigurations = [
                  {
                    id = "string"
                    name = "string"
                    properties = {
                      subnet = {
                        id = "string"
                      }
                    }
                  }
                ]
                delegations = [
                  {
                    id = "string"
                    name = "string"
                    properties = {
                      serviceName = "string"
                    }
                    type = "string"
                  }
                ]
                ipAllocations = [
                  {
                    id = "string"
                  }
                ]
                natGateway = {
                  id = "string"
                }
                networkSecurityGroup = {
                  id = "string"
                  location = "string"
                  properties = {
                    flushConnection = bool
                    securityRules = [
                      {
                        id = "string"
                        name = "string"
                        properties = {
                          access = "string"
                          description = "string"
                          destinationAddressPrefix = "string"
                          destinationAddressPrefixes = [
                            "string"
                          ]
                          destinationApplicationSecurityGroups = [
                            {
                              id = "string"
                              location = "string"
                              properties = {}
                              tags = {}
                            }
                          ]
                          destinationPortRange = "string"
                          destinationPortRanges = [
                            "string"
                          ]
                          direction = "string"
                          priority = int
                          protocol = "string"
                          sourceAddressPrefix = "string"
                          sourceAddressPrefixes = [
                            "string"
                          ]
                          sourceApplicationSecurityGroups = [
                            {
                              id = "string"
                              location = "string"
                              properties = {}
                              tags = {}
                            }
                          ]
                          sourcePortRange = "string"
                          sourcePortRanges = [
                            "string"
                          ]
                        }
                        type = "string"
                      }
                    ]
                  }
                  tags = {}
                }
                privateEndpointNetworkPolicies = "string"
                privateLinkServiceNetworkPolicies = "string"
                routeTable = {
                  id = "string"
                  location = "string"
                  properties = {
                    disableBgpRoutePropagation = bool
                    routes = [
                      {
                        id = "string"
                        name = "string"
                        properties = {
                          addressPrefix = "string"
                          hasBgpOverride = bool
                          nextHopIpAddress = "string"
                          nextHopType = "string"
                        }
                        type = "string"
                      }
                    ]
                  }
                  tags = {}
                }
                serviceEndpointPolicies = [
                  {
                    id = "string"
                    location = "string"
                    properties = {
                      contextualServiceEndpointPolicies = [
                        "string"
                      ]
                      serviceAlias = "string"
                      serviceEndpointPolicyDefinitions = [
                        {
                          id = "string"
                          name = "string"
                          properties = {
                            description = "string"
                            service = "string"
                            serviceResources = [
                              "string"
                            ]
                          }
                          type = "string"
                        }
                      ]
                    }
                    tags = {}
                  }
                ]
                serviceEndpoints = [
                  {
                    locations = [
                      "string"
                    ]
                    service = "string"
                  }
                ]
              }
              type = "string"
            }
          }
          zones = [
            "string"
          ]
        }
      ]
      inboundNatPools = [
        {
          id = "string"
          name = "string"
          properties = {
            backendPort = int
            enableFloatingIP = bool
            enableTcpReset = bool
            frontendIPConfiguration = {
              id = "string"
            }
            frontendPortRangeEnd = int
            frontendPortRangeStart = int
            idleTimeoutInMinutes = int
            protocol = "string"
          }
        }
      ]
      inboundNatRules = [
        {
          id = "string"
          name = "string"
          properties = {
            backendAddressPool = {
              id = "string"
            }
            backendPort = int
            enableFloatingIP = bool
            enableTcpReset = bool
            frontendIPConfiguration = {
              id = "string"
            }
            frontendPort = int
            frontendPortRangeEnd = int
            frontendPortRangeStart = int
            idleTimeoutInMinutes = int
            protocol = "string"
          }
        }
      ]
      loadBalancingRules = [
        {
          id = "string"
          name = "string"
          properties = {
            backendAddressPool = {
              id = "string"
            }
            backendAddressPools = [
              {
                id = "string"
              }
            ]
            backendPort = int
            disableOutboundSnat = bool
            enableFloatingIP = bool
            enableTcpReset = bool
            frontendIPConfiguration = {
              id = "string"
            }
            frontendPort = int
            idleTimeoutInMinutes = int
            loadDistribution = "string"
            probe = {
              id = "string"
            }
            protocol = "string"
          }
        }
      ]
      outboundRules = [
        {
          id = "string"
          name = "string"
          properties = {
            allocatedOutboundPorts = int
            backendAddressPool = {
              id = "string"
            }
            enableTcpReset = bool
            frontendIPConfigurations = [
              {
                id = "string"
              }
            ]
            idleTimeoutInMinutes = int
            protocol = "string"
          }
        }
      ]
      probes = [
        {
          id = "string"
          name = "string"
          properties = {
            intervalInSeconds = int
            numberOfProbes = int
            port = int
            probeThreshold = int
            protocol = "string"
            requestPath = "string"
          }
        }
      ]
    }
    sku = {
      name = "string"
      tier = "string"
    }
    extendedLocation = {
      name = "string"
      type = "EdgeZone"
    }
  })
}

屬性值

loadBalancers

名稱 描述
類型 資源類型 “Microsoft.Network/loadBalancers@2023-04-01”
NAME 資源名稱 字串 (必要)

字元限制:1-80

合法字元:
英數字元、底線、句號和連字號。

以英數字元開頭。 以英數字元或底線結尾。
location 資源位置。 字串
parent_id 若要部署至資源群組,請使用該資源群組的標識碼。 字串 (必要)
tags 資源標籤。 標記名稱和值的字典。
sku 負載平衡器 SKU。 LoadBalancerSku
extendedLocation 負載平衡器的擴充位置。 ExtendedLocation
properties 負載平衡器的屬性。 LoadBalancerPropertiesFormat

ExtendedLocation

名稱 描述
NAME 擴充位置的名稱。 字串
type 擴充位置的類型。 “EdgeZone”

LoadBalancerPropertiesFormat

名稱 描述
backendAddressPools 負載平衡器所使用的後端位址池集合。 BackendAddressPool[]
frontendIPConfigurations 物件,表示要用於負載平衡器的前端IP。 FrontendIPConfiguration[]
inboundNatPools 定義與負載平衡器相關聯之 NIC 上輸入 NAT 到單一後埠的外部埠範圍。 輸入 NAT 規則會自動針對使用此範圍的外部埠,針對與 Load Balancer 相關聯的每個 NIC 建立。 在 Load Balancer 上定義輸入NAT集區與定義輸入NAT規則互斥。 從虛擬機擴展集參考輸入NAT集區。 與個別虛擬機相關聯的 NIC 無法參考輸入 NAT 集區。 它們必須參考個別的輸入NAT規則。 InboundNatPool[]
inboundNatRules 負載平衡器所使用的輸入NAT規則集合。 在負載平衡器上定義輸入NAT規則與定義輸入NAT集區互斥。 從虛擬機擴展集參考輸入NAT集區。 與個別虛擬機相關聯的 NIC 無法參考輸入 NAT 集區。 它們必須參考個別的輸入NAT規則。 InboundNatRule[]
loadBalancingRules 代表負載平衡規則的物件集合 取得布建。 LoadBalancingRule[]
outboundRules 輸出規則。 OutboundRule[]
探查 負載平衡器中使用的探查物件集合。 探查[]

BackendAddressPool

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的後端位址池集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器後端位址池的屬性。 BackendAddressPoolPropertiesFormat

BackendAddressPoolPropertiesFormat

名稱 描述
drainPeriodInSeconds 將 RESET 傳送至用戶端和後端位址之前,Load Balancer 等候的秒數。 int
loadBalancerBackendAddresses 後端位址的陣列。 LoadBalancerBackendAddress[]
location 後端位址池的位置。 字串
syncMode 後端集區的後端位址同步模式 “Automatic”
“Manual”
tunnelInterfaces 閘道連接平衡器通道介面的陣列。 GatewayLoadBalancerTunnelInterface[]
virtualNetwork 虛擬網路的參考。 SubResource

LoadBalancerBackendAddress

名稱 描述
NAME 後端位址的名稱。 字串
properties 負載平衡器後端位址池的屬性。 LoadBalancerBackendAddressPropertiesFormat

LoadBalancerBackendAddressPropertiesFormat

名稱 描述
adminState 系統管理狀態清單,一旦設定即可覆寫健康情況探查,讓 Load Balancer 一律會將新的連線轉送至後端,或拒絕新的連線並重設現有的連線。 “Down”
"None"
“Up”
ipAddress 屬於參考虛擬網路的IP位址。 字串
loadBalancerFrontendIPConfiguration 區域負載平衡器中定義的前端IP位址組態參考。 SubResource
子網路 現有子網的參考。 SubResource
virtualNetwork 現有虛擬網路的參考。 SubResource

SubResource

名稱 描述
id 資源識別碼。 字串

GatewayLoadBalancerTunnelInterface

名稱 描述
識別碼 (identifier) 閘道連接平衡器通道介面的識別碼。 int
連接埠 閘道連接平衡器通道介面的埠。 int
protocol 閘道連接平衡器通道介面的通訊協定。 “Native”
"None"
“VXLAN”
類型 閘道連接平衡器通道介面的流量類型。 “外部”
“內部”
"None"

FrontendIPConfiguration

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的一組前端IP組態內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器探查的屬性。 FrontendIPConfigurationPropertiesFormat
zones (區域) 可用性區域清單,指出為資源配置的IP需要來自。 string[]

FrontendIPConfigurationPropertiesFormat

名稱 描述
gatewayLoadBalancer 閘道負載平衡器前端IP的參考。 SubResource
privateIPAddress IP 組態的私人IP位址。 字串
privateIPAddressVersion 特定 ipconfiguration 是 IPv4 或 IPv6。 預設值會採用為 IPv4。 “IPv4”
“IPv6”
privateIPAllocationMethod 私人IP配置方法。 “動態”
“Static”
publicIPAddress 公用IP資源的參考。 PublicIPAddress
publicIPPrefix 公用IP前置綴資源的參考。 SubResource
子網路 子網資源的參考。 子網路

PublicIPAddress

名稱 描述
extendedLocation 公用IP位址的擴充位置。 ExtendedLocation
id 資源識別碼。 字串
location 資源位置。 字串
properties 公用IP位址屬性。 PublicIPAddressPropertiesFormat
sku 公用IP位址 SKU。 PublicIPAddressSku
tags 資源標籤。 物件 (object)
zones (區域) 可用性區域清單,指出為資源配置的IP必須來自。 string[]

PublicIPAddressPropertiesFormat

名稱 描述
ddosSettings 與公用IP位址相關聯的 DDoS 保護自定義原則。 DdosSettings
deleteOption 指定刪除 VM 時,公用 IP 位址會發生什麼情況 "Delete"
“Detach”
dnsSettings 與公用IP位址相關聯的 DNS 記錄 FQDN。 PublicIPAddressDnsSettings
idleTimeoutInMinutes 公用IP位址的閒置逾時。 int
ipAddress 與公用IP位址資源相關聯的IP位址。 字串
ipTags 與公用IP位址相關聯的標記清單。 IpTag[]
linkedPublicIPAddress 公用IP位址資源的連結公用IP位址。 PublicIPAddress
migrationPhase 公用IP位址的移轉階段。 “中止”
“Commit”
“Committed”
"None"
“Prepare”
natGateway 公用IP位址的 NatGateway。 NatGateway
publicIPAddressVersion 公用IP位址版本。 “IPv4”
“IPv6”
publicIPAllocationMethod 公用IP位址配置方法。 “Dynamic”
“Static”
publicIPPrefix 此公用 IP 位址的公用 IP 前置碼應該設定自 。 SubResource
servicePublicIPAddress 公用IP位址資源的服務公用IP位址。 PublicIPAddress

DdosSettings

名稱 描述
ddosProtectionPlan 與公用IP相關聯的 DDoS 保護計劃。 只有在 ProtectionMode 已啟用時,才能設定 SubResource
protectionMode 公用IP的 DDoS 保護模式 “Disabled”
“Enabled”
“VirtualNetworkInherited”

PublicIPAddressDnsSettings

名稱 描述
domainNameLabel 功能變數名稱標籤。 網域名稱標籤和已進行地區設定之 DNS 區域的串連可組成和公用 IP 位址相關聯的完整網域名稱。 如果已指定網域名稱標籤,則會在 Microsoft Azure DNS 系統中為公用 IP 建立 DNS 記錄。 字串
domainNameLabelScope 功能變數名稱標籤範圍。 如果指定功能變數名稱標籤和功能變數名稱標籤範圍,則會針對 Microsoft Azure DNS 系統中的公用 IP 建立 DNS 記錄,其中包含 FQDN 中的哈希值。 “NoReuse”
“ResourceGroupReuse”
“SubscriptionReuse”
“TenantReuse”
fqdn 與公用IP相關聯的 A DNS 記錄的完整功能變數名稱。 這是 domainNameLabel 和區域化 DNS 區域的串連。 字串
reverseFqdn 反向 FQDN。 可解析為這個公用IP位址的用戶可見完整功能變數名稱。 如果已指定 reverseFqdn,則會建立 PTR DNS 記錄,從 in-addr.arpa 網域中的 IP 位址指向反向 FQDN。 字串

IpTag

名稱 描述
ipTagType IP 標籤類型。 範例:FirstPartyUsage。 字串
標籤 與公用IP相關聯的IP標籤。 範例:SQL。 字串

NatGateway

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties Nat 閘道屬性。 NatGatewayPropertiesFormat
sku nat 閘道 SKU。 NatGatewaySku
tags 資源標籤。 物件 (object)
zones (區域) 可用性區域清單,指出應該在其中部署 Nat 閘道的區域。 string[]

NatGatewayPropertiesFormat

名稱 描述
idleTimeoutInMinutes nat 閘道的閒置逾時。 int
publicIpAddresses 與 nat 閘道資源相關聯的公用IP位址數位。 SubResource[]
publicIpPrefixes 與 nat 閘道資源相關聯的公用IP前置詞數位。 SubResource[]

NatGatewaySku

名稱 描述
NAME Nat 閘道 SKU 的名稱。 “Standard”

PublicIPAddressSku

名稱 描述
NAME 公用IP位址 SKU 的名稱。 "Basic"
“Standard”
tier 公用IP位址SKU的階層。 “Global”
“區域”

子網路

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 子網的屬性。 SubnetPropertiesFormat
類型 資源類型。 字串

SubnetPropertiesFormat

名稱 描述
addressPrefix 子網的位址前置詞。 字串
addressPrefixes 子網的位址前置詞清單。 string[]
applicationGatewayIPConfigurations 虛擬網路資源的應用程式閘道IP組態。 ApplicationGatewayIPConfiguration[]
代表團 子網上委派的參考陣列。 委派[]
ipAllocations 參考此子網的 IpAllocation 陣列。 SubResource[]
natGateway 與此子網相關聯的 Nat 閘道。 SubResource
networkSecurityGroup NetworkSecurityGroup 資源的參考。 NetworkSecurityGroup
privateEndpointNetworkPolicies 在子網的私人端點上啟用或停用套用網路原則。 “Disabled”
“Enabled”
privateLinkServiceNetworkPolicies 在子網中的私人連結服務上啟用或停用套用網路原則。 “Disabled”
“Enabled”
routeTable RouteTable 資源的參考。 RouteTable
serviceEndpointPolicies 服務端點原則的陣列。 ServiceEndpointPolicy[]
serviceEndpoints 服務端點的陣列。 ServiceEndpointPropertiesFormat[]

ApplicationGatewayIPConfiguration

名稱 描述
id 資源識別碼。 字串
NAME 應用程式閘道 內唯一的IP組態名稱。 字串
properties 應用程式閘道IP組態的屬性。 ApplicationGatewayIPConfigurationPropertiesFormat

ApplicationGatewayIPConfigurationPropertiesFormat

名稱 描述
子網路 子網資源的參考。 應用程式閘道從中取得其私人位址的子網。 SubResource

委派

名稱 描述
id 資源識別碼。 字串
NAME 子網內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 子網的屬性。 ServiceDelegationPropertiesFormat
類型 資源類型。 字串

ServiceDelegationPropertiesFormat

名稱 描述
serviceName 子網應委派給的服務名稱 (,例如 Microsoft.Sql/servers) 。 字串

NetworkSecurityGroup

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 網路安全組的屬性。 NetworkSecurityGroupPropertiesFormat
tags 資源標籤。 物件 (object)

NetworkSecurityGroupPropertiesFormat

名稱 描述
flushConnection 啟用時,從網路安全組連線建立的流程會在更新規則時重新評估。 初始啟用將會觸發重新評估。 bool
securityRules 網路安全組的安全性規則集合。 SecurityRule[]

SecurityRule

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 安全性規則的屬性。 SecurityRulePropertiesFormat
類型 資源類型。 字串

SecurityRulePropertiesFormat

名稱 描述
access 允許或拒絕網路流量。 “允許”
“Deny” (必要)
description 此規則的說明。 限制為140個字元。 字串
destinationAddressPrefix 目的地地址前綴。 CIDR 或目的地IP範圍。 也可用星號 (*) 來比對所有的來源 IP。 您也可以使用默認標籤,例如 'VirtualNetwork'、'AzureLoadBalancer' 和 'Internet'。 字串
destinationAddressPrefixes 目的地位址前置詞。 CIDR 或目的地IP範圍。 string[]
destinationApplicationSecurityGroups 指定為目的地的應用程式安全組。 ApplicationSecurityGroup[]
destinationPortRange 目的地埠或範圍。 介於 0 到 65535 之間的整數或範圍。 星號 『*』 也可以用來比對所有埠。 字串
destinationPortRanges 目的地埠範圍。 string[]
direction 規則的方向。 此方向指定是否根據連入或連出的流量評估規則。 “Inbound”
「輸出」 (必要)
priority 規則的優先順序。 此值可以介於 100 到 4096 之間。 集合中每個規則的優先順序數字必須是唯一的。 優先順序號碼愈小,規則優先順序就愈高。 需要 int ()
protocol 此規則適用的網路通訊協定。 "*"
“Ah”
“Esp”
“Icmp”
“Tcp”
必要 “Udp” ()
sourceAddressPrefix CIDR 或來源IP範圍。 也可用星號 (*) 來比對所有的來源 IP。 您也可以使用默認標籤,例如 'VirtualNetwork'、'AzureLoadBalancer' 和 'Internet'。 如果這是輸入規則,請指定網路流量的來源。 字串
sourceAddressPrefixes CIDR 或來源IP範圍。 string[]
sourceApplicationSecurityGroups 指定為來源的應用程式安全組。 ApplicationSecurityGroup[]
sourcePortRange 來源埠或範圍。 介於 0 到 65535 之間的整數或範圍。 星號 『*』 也可以用來比對所有埠。 字串
sourcePortRanges 來源埠範圍。 string[]

ApplicationSecurityGroup

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 應用程式安全組的屬性。 ApplicationSecurityGroupPropertiesFormat
tags 資源標籤。 物件 (object)

ApplicationSecurityGroupPropertiesFormat

此物件不包含部署期間要設定的任何屬性。 所有屬性都是 ReadOnly。

RouteTable

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 路由表的屬性。 RouteTablePropertiesFormat
tags 資源標籤。 物件 (object)

RouteTablePropertiesFormat

名稱 描述
disableBgpRoutePropagation 是否要在該路由表上停用 BGP 所學習的路由。 True 表示停用。 bool
路由 路由表內含的路由集合。 Route[]

路由

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 路由的屬性。 RoutePropertiesFormat
類型 資源類型。 字串

RoutePropertiesFormat

名稱 描述
addressPrefix 路由套用的目標 CIDR。 字串
hasBgpOverride 值,指出不論 LPM 為何,此路由是否覆寫重疊的 BGP 路由。 bool
nextHopIpAddress IP 位址封包應轉送至 。 下一個躍點值只能在下一個躍點類型為 VirtualAppliance 的路由中允許。 字串
nextHopType 要接收封包的 Azure 躍點的類型。 “Internet”
"None"
“VirtualAppliance”
“VirtualNetworkGateway”
必要 (「VnetLocal」)

ServiceEndpointPolicy

名稱 描述
id 資源識別碼。 字串
location 資源位置。 字串
properties 服務端點原則的屬性。 ServiceEndpointPolicyPropertiesFormat
tags 資源標籤。 物件 (object)

ServiceEndpointPolicyPropertiesFormat

名稱 描述
contextualServiceEndpointPolicies 內容服務端點原則的集合。 string[]
serviceAlias 指出原則是否屬於服務的別名 字串
serviceEndpointPolicyDefinitions 服務端點原則的服務端點原則定義集合。 ServiceEndpointPolicyDefinition[]

ServiceEndpointPolicyDefinition

名稱 描述
id 資源識別碼。 字串
NAME 資源群組內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 服務端點原則定義的屬性。 ServiceEndpointPolicyDefinitionPropertiesFormat
類型 資源類型。 字串

ServiceEndpointPolicyDefinitionPropertiesFormat

名稱 描述
description 此規則的說明。 限制為140個字元。 字串
service 服務端點名稱。 字串
serviceResources 服務資源的清單。 string[]

ServiceEndpointPropertiesFormat

名稱 描述
位置 位置清單。 string[]
service 端點服務的型別。 字串

InboundNatPool

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之輸入NAT集區集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸入 nat 集區的屬性。 InboundNatPoolPropertiesFormat

InboundNatPoolPropertiesFormat

名稱 描述
backendPort 在端點上用於內部連接的連接埠。 可接受的值介於 1 到 65535 之間。 int (必要)
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPortRangeEnd 外部埠範圍中的最後一個埠號碼,用來將輸入 Nat 提供給與負載平衡器相關聯的 NIC。 可接受的值介於 1 到 65535 之間。 int (必要)
frontendPortRangeStart 外部埠範圍中的第一個埠號碼,用來將輸入 Nat 提供給與負載平衡器相關聯的 NIC。 可接受的值介於 1 到 65534 之間。 int (必要)
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
protocol 輸入 NAT 集區所使用的傳輸通訊協議參考。 "All"
“Tcp”
必要) “Udp” (

InboundNatRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用之輸入NAT規則集合內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸入NAT規則的屬性。 InboundNatRulePropertiesFormat

InboundNatRulePropertiesFormat

名稱 描述
backendAddressPool backendAddressPool 資源的參考。 SubResource
backendPort 內部端點使用的連接埠。 可接受的值範圍從 1 到 65535。 int
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPort 外部端點的連接埠。 每個規則的埠號碼在 Load Balancer 內必須是唯一的。 可接受的值範圍從 1 到 65534。 int
frontendPortRangeEnd 外部端點的埠範圍結束。 此屬性會與 BackendAddressPool 和 FrontendPortRangeStart 搭配使用。 系統會為每個後端位址建立來自 BackendAddressPool 的個別輸入 NAT 規則埠對應。 可接受的值範圍從 1 到 65534。 int
frontendPortRangeStart 外部端點的埠範圍開始。 此屬性會與 BackendAddressPool 和 FrontendPortRangeEnd 搭配使用。 系統會為每個後端位址建立來自 BackendAddressPool 的個別輸入 NAT 規則埠對應。 可接受的值範圍從 1 到 65534。 int
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
protocol 負載平衡規則所使用的傳輸通訊協議參考。 "All"
“Tcp”
“Udp”

LoadBalancingRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用的負載平衡規則集內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器負載平衡規則的屬性。 LoadBalancingRulePropertiesFormat

LoadBalancingRulePropertiesFormat

名稱 描述
backendAddressPool DIP 集區的參考。 輸入流量會在後端IP中的IP之間隨機負載平衡。 SubResource
backendAddressPools DIP 集區的參考陣列。 SubResource[]
backendPort 在端點上用於內部連接的連接埠。 可接受的值為 0 到 65535。 請注意,值 0 會啟用「任何埠」。 int
disableOutboundSnat 設定後端集區中 VM 的 SNAT,以使用負載平衡規則前端中指定的 publicIP 位址。 bool
enableFloatingIP 針對設定 SQL AlwaysOn 可用性群組所需的浮動 IP 功能,設定虛擬機的端點。 使用 SQL Server 中的 SQL AlwaysOn 可用性群組時,需要此設定。 建立端點之後,就無法變更此設定。 bool
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfiguration 前端IP位址的參考。 SubResource
frontendPort 外部端點的連接埠。 每個規則的埠號碼在 Load Balancer 內必須是唯一的。 可接受的值為 0 到 65534。 請注意,值 0 會啟用「任何埠」。 需要 int ()
idleTimeoutInMinutes TCP 閑置連線的逾時。 此值可介於 4 與 30 分鐘之間。 預設值為 4 分鐘。 此元素只限於通訊協定設定為 TCP 時才會使用。 int
loadDistribution 此規則的負載分配原則。 “預設值”
“SourceIP”
“SourceIPProtocol”
探查 負載平衡規則所使用的負載平衡器探查參考。 SubResource
protocol 負載平衡規則所使用的傳輸通訊協議參考。 "All"
“Tcp”
必要 “Udp” ()

OutboundRule

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用輸出規則集內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器輸出規則的屬性。 OutboundRulePropertiesFormat

OutboundRulePropertiesFormat

名稱 描述
allocatedOutboundPorts 要用於 NAT 的輸出埠數目。 int
backendAddressPool DIP 集區的參考。 輸出流量會在後端IP中的IP之間隨機負載平衡。 必要子資源 ()
enableTcpReset 在 TCP 流量閒置逾時或非預期的連線終止時接收雙向 TCP 重設。 此元素只限於通訊協定設定為 TCP 時才會使用。 bool
frontendIPConfigurations 負載平衡器的前端IP位址。 SubResource[] (必要)
idleTimeoutInMinutes TCP 閑置連線的逾時。 int
protocol 負載平衡器中輸出規則的通訊協定。 "All"
“Tcp”
必要 “Udp” ()

探查

名稱 描述
id 資源識別碼。 字串
NAME 負載平衡器所使用探查集內唯一的資源名稱。 此名稱可用來存取資源。 字串
properties 負載平衡器探查的屬性。 ProbePropertiesFormat

ProbePropertiesFormat

名稱 描述
intervalInSeconds 探查端點健康情況狀態的頻率間隔 (以秒為單位)。 一般而言,間隔略小於配置逾時期間 (以秒為單位) 的一半,可允許在執行個體退出循環之前進行兩個完整探查。 預設值是 15,最小值是 5。 int
numberOfProbes 如果沒有回應,則探查數目會導致停止將進一步的流量傳遞至端點。 這個值可讓端點比 Azure 中使用的一般時間更快或更慢地從旋轉中取出。 int
連接埠 用來與探查通訊的連接埠。 可能的值範圍從 1 到 65535 (含)。 需要 int ()
probeThreshold 連續成功或失敗的探查數目,以允許或拒絕傳送至此端點的流量。 失敗等於此值的連續探查數目之後,端點將會從輪替中取出,而且需要將相同的連續探查數目放在旋轉中。 int
protocol 端點的通訊協定。 如果指定了 『Tcp』,則需要接收的 ACK,才能成功探查。 如果指定 'Http' 或 'Https',則需要來自 指定 URI 的 200 OK 回應,探查才能成功。 “Http”
“Https”
“Tcp” (必要)
requestPath 用來從 VM 要求健康情況狀態的 URI。 如果通訊協定設定為 HTTP,則需要路徑。 否則不允許。 沒有任何預設值。 字串

LoadBalancerSku

名稱 描述
NAME 負載平衡器 SKU 的名稱。 "Basic"
“Gateway”
“Standard”
tier 負載平衡器 SKU 的階層。 “Global”
“區域”