Microsoft.網路連線 2015-05-01-preview
Bicep 資源定義
您可以使用目標作業來部署連線資源類型:
如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。
若要建立 Microsoft.Network/connections 資源,請將下列 Bicep 新增至您的範本。
resource symbolicname 'Microsoft.Network/connections@2015-05-01-preview' = {
etag: 'string'
location: 'string'
name: 'string'
properties: {
connectionStatus: 'string'
connectionType: 'string'
egressBytesTransferred: int
ingressBytesTransferred: int
localNetworkGateway2: {
etag: 'string'
location: 'string'
properties: {
gatewayIpAddress: 'string'
localNetworkAddressSpace: {
addressPrefixes: [
'string'
]
}
provisioningState: 'string'
resourceGuid: 'string'
}
tags: {
{customized property}: 'string'
}
}
peer: {
id: 'string'
}
provisioningState: 'string'
resourceGuid: 'string'
routingWeight: int
sharedKey: 'string'
virtualNetworkGateway1: {
etag: 'string'
location: 'string'
properties: {
enableBgp: bool
gatewayDefaultSite: {
id: 'string'
}
gatewayType: 'string'
ipConfigurations: [
{
etag: 'string'
id: 'string'
name: 'string'
properties: {
privateIPAddress: 'string'
privateIPAllocationMethod: 'string'
provisioningState: 'string'
publicIPAddress: {
id: 'string'
}
subnet: {
id: 'string'
}
}
}
]
provisioningState: 'string'
resourceGuid: 'string'
vpnType: 'string'
}
tags: {
{customized property}: 'string'
}
}
virtualNetworkGateway2: {
etag: 'string'
location: 'string'
properties: {
enableBgp: bool
gatewayDefaultSite: {
id: 'string'
}
gatewayType: 'string'
ipConfigurations: [
{
etag: 'string'
id: 'string'
name: 'string'
properties: {
privateIPAddress: 'string'
privateIPAllocationMethod: 'string'
provisioningState: 'string'
publicIPAddress: {
id: 'string'
}
subnet: {
id: 'string'
}
}
}
]
provisioningState: 'string'
resourceGuid: 'string'
vpnType: 'string'
}
tags: {
{customized property}: 'string'
}
}
}
tags: {
{customized property}: 'string'
}
}
屬性值
AddressSpace
名字 |
描述 |
價值 |
addressPrefixes |
取得或設定在 CIDR 表示法中保留給此虛擬網路的位址區塊清單 |
string[] |
LocalNetworkGateway
名字 |
描述 |
價值 |
gatewayIpAddress |
局域網路閘道的IP位址。 |
字串 |
localNetworkAddressSpace |
局域網路網站位址空間 |
AddressSpace |
provisioningState |
取得或設定 LocalNetworkGateway 資源的布建狀態更新/刪除/失敗 |
字串 |
resourceGuid |
取得或設定 LocalNetworkGateway 資源的資源 GUID 屬性 |
字串 |
Microsoft.Network/connections
SubResource
VirtualNetworkGateway
名字 |
描述 |
價值 |
connectionStatus |
虛擬網路網關聯機狀態 |
'Connected' '聯機' 'NotConnected' 'Unknown' |
connectionType |
網關聯機類型 IPsec/Dedicated/VpnClient/Vnet2Vnet |
'ExpressRoute' 'IPsec' 'Vnet2Vnet' 'VPNClient' |
egressBytesTransferred |
在此連線中傳輸的輸出位元組 |
int |
ingressBytesTransferred |
在此連線中傳輸的輸入位元組 |
int |
localNetworkGateway2 |
一般資源資訊的通用類別 |
LocalNetworkGateway |
同輩 |
對等互連資源的參考。 |
SubResource |
provisioningState |
取得或設定 VirtualNetworkGatewayConnection 資源更新/刪除/失敗的布建狀態 |
字串 |
resourceGuid |
取得或設定 VirtualNetworkGatewayConnection 資源的資源 guid 屬性 |
字串 |
routingWeight |
路由權數。 |
int |
sharedKey |
IPsec 共用金鑰。 |
字串 |
virtualNetworkGateway1 |
一般資源資訊的通用類別 |
VirtualNetworkGateway |
virtualNetworkGateway2 |
一般資源資訊的通用類別 |
VirtualNetworkGateway |
VirtualNetworkGatewayIpConfiguration
名字 |
描述 |
價值 |
privateIPAddress |
取得或設定網路介面IP組態的 privateIPAddress |
字串 |
privateIPAllocationMethod |
取得或設定 PrivateIP 設定方法 (靜態/動態) |
'Dynamic' 'Static' |
provisioningState |
取得或設定 PublicIP 資源更新/刪除/失敗的布建狀態 |
字串 |
publicIPAddress |
取得或設定 PublicIP 資源的參考 |
SubResource |
子 |
取得或設定子網資源的參考 |
SubResource |
名字 |
描述 |
價值 |
enableBgp |
EnableBgp 旗標 |
bool |
gatewayDefaultSite |
取得或設定 LocalNetworkGateway 資源的參考,代表具有預設路由的局域網路網站。 如果移除現有的默認網站設定,請指派 Null 值。 |
SubResource |
gatewayType |
此虛擬網路閘道的類型。 |
'ExpressRoute' 'Vpn' |
ipConfigurations |
虛擬網路閘道的 IpConfigurations。 |
VirtualNetworkGatewayIpConfiguration[] |
provisioningState |
取得或設定 VirtualNetworkGateway 資源的布建狀態更新/刪除/失敗 |
字串 |
resourceGuid |
取得或設定 VirtualNetworkGateway 資源的資源 GUID 屬性 |
字串 |
vpnType |
此虛擬網路閘道的類型。 |
'PolicyBased' 'RouteBased' |
快速入門範例
下列快速入門範例會部署此資源類型。
Bicep 檔案 |
描述 |
建立 BGP VNET 對 VNET 連線 |
此範本可讓您使用虛擬網路閘道和 BGP 連線兩個 VNET |
使用 BGP 使用主動 VPN 閘道 站對站 VPN VPN |
此範本可讓您在具有 VPN 閘道的兩個 VNet 之間部署站對站 VPN,以使用 BGP 設定主動-主動。 每個 Azure VPN 閘道都會解析遠端對等的 FQDN,以判斷遠端 VPN 閘道的公用 IP。 範本會在具有可用性區域的 Azure 區域中如預期般執行。 |
ARM 樣本資源定義
您可以使用目標作業來部署連線資源類型:
如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。
若要建立 Microsoft.Network/connections 資源,請將下列 JSON 新增至範本。
{
"type": "Microsoft.Network/connections",
"apiVersion": "2015-05-01-preview",
"name": "string",
"etag": "string",
"location": "string",
"properties": {
"connectionStatus": "string",
"connectionType": "string",
"egressBytesTransferred": "int",
"ingressBytesTransferred": "int",
"localNetworkGateway2": {
"etag": "string",
"location": "string",
"properties": {
"gatewayIpAddress": "string",
"localNetworkAddressSpace": {
"addressPrefixes": [ "string" ]
},
"provisioningState": "string",
"resourceGuid": "string"
},
"tags": {
"{customized property}": "string"
}
},
"peer": {
"id": "string"
},
"provisioningState": "string",
"resourceGuid": "string",
"routingWeight": "int",
"sharedKey": "string",
"virtualNetworkGateway1": {
"etag": "string",
"location": "string",
"properties": {
"enableBgp": "bool",
"gatewayDefaultSite": {
"id": "string"
},
"gatewayType": "string",
"ipConfigurations": [
{
"etag": "string",
"id": "string",
"name": "string",
"properties": {
"privateIPAddress": "string",
"privateIPAllocationMethod": "string",
"provisioningState": "string",
"publicIPAddress": {
"id": "string"
},
"subnet": {
"id": "string"
}
}
}
],
"provisioningState": "string",
"resourceGuid": "string",
"vpnType": "string"
},
"tags": {
"{customized property}": "string"
}
},
"virtualNetworkGateway2": {
"etag": "string",
"location": "string",
"properties": {
"enableBgp": "bool",
"gatewayDefaultSite": {
"id": "string"
},
"gatewayType": "string",
"ipConfigurations": [
{
"etag": "string",
"id": "string",
"name": "string",
"properties": {
"privateIPAddress": "string",
"privateIPAllocationMethod": "string",
"provisioningState": "string",
"publicIPAddress": {
"id": "string"
},
"subnet": {
"id": "string"
}
}
}
],
"provisioningState": "string",
"resourceGuid": "string",
"vpnType": "string"
},
"tags": {
"{customized property}": "string"
}
}
},
"tags": {
"{customized property}": "string"
}
}
屬性值
AddressSpace
名字 |
描述 |
價值 |
addressPrefixes |
取得或設定在 CIDR 表示法中保留給此虛擬網路的位址區塊清單 |
string[] |
LocalNetworkGateway
名字 |
描述 |
價值 |
gatewayIpAddress |
局域網路閘道的IP位址。 |
字串 |
localNetworkAddressSpace |
局域網路網站位址空間 |
AddressSpace |
provisioningState |
取得或設定 LocalNetworkGateway 資源的布建狀態更新/刪除/失敗 |
字串 |
resourceGuid |
取得或設定 LocalNetworkGateway 資源的資源 GUID 屬性 |
字串 |
Microsoft.Network/connections
名字 |
描述 |
價值 |
apiVersion |
API 版本 |
'2015-05-01-preview' |
etag |
取得唯一的唯一 |
字串 |
位置 |
資源位置 |
字串 (必要) |
名字 |
資源名稱 |
字串 (必要) |
性能 |
VirtualNetworkGatewayConnection 属性 |
VirtualNetworkGatewayConnectionPropertiesFormat |
標籤 |
資源標籤 |
標記名稱和值的字典。 請參閱範本中的 標籤 |
類型 |
資源類型 |
'Microsoft.Network/connections' |
SubResource
VirtualNetworkGateway
名字 |
描述 |
價值 |
connectionStatus |
虛擬網路網關聯機狀態 |
'Connected' '聯機' 'NotConnected' 'Unknown' |
connectionType |
網關聯機類型 IPsec/Dedicated/VpnClient/Vnet2Vnet |
'ExpressRoute' 'IPsec' 'Vnet2Vnet' 'VPNClient' |
egressBytesTransferred |
在此連線中傳輸的輸出位元組 |
int |
ingressBytesTransferred |
在此連線中傳輸的輸入位元組 |
int |
localNetworkGateway2 |
一般資源資訊的通用類別 |
LocalNetworkGateway |
同輩 |
對等互連資源的參考。 |
SubResource |
provisioningState |
取得或設定 VirtualNetworkGatewayConnection 資源更新/刪除/失敗的布建狀態 |
字串 |
resourceGuid |
取得或設定 VirtualNetworkGatewayConnection 資源的資源 guid 屬性 |
字串 |
routingWeight |
路由權數。 |
int |
sharedKey |
IPsec 共用金鑰。 |
字串 |
virtualNetworkGateway1 |
一般資源資訊的通用類別 |
VirtualNetworkGateway |
virtualNetworkGateway2 |
一般資源資訊的通用類別 |
VirtualNetworkGateway |
VirtualNetworkGatewayIpConfiguration
名字 |
描述 |
價值 |
privateIPAddress |
取得或設定網路介面IP組態的 privateIPAddress |
字串 |
privateIPAllocationMethod |
取得或設定 PrivateIP 設定方法 (靜態/動態) |
'Dynamic' 'Static' |
provisioningState |
取得或設定 PublicIP 資源更新/刪除/失敗的布建狀態 |
字串 |
publicIPAddress |
取得或設定 PublicIP 資源的參考 |
SubResource |
子 |
取得或設定子網資源的參考 |
SubResource |
名字 |
描述 |
價值 |
enableBgp |
EnableBgp 旗標 |
bool |
gatewayDefaultSite |
取得或設定 LocalNetworkGateway 資源的參考,代表具有預設路由的局域網路網站。 如果移除現有的默認網站設定,請指派 Null 值。 |
SubResource |
gatewayType |
此虛擬網路閘道的類型。 |
'ExpressRoute' 'Vpn' |
ipConfigurations |
虛擬網路閘道的 IpConfigurations。 |
VirtualNetworkGatewayIpConfiguration[] |
provisioningState |
取得或設定 VirtualNetworkGateway 資源的布建狀態更新/刪除/失敗 |
字串 |
resourceGuid |
取得或設定 VirtualNetworkGateway 資源的資源 GUID 屬性 |
字串 |
vpnType |
此虛擬網路閘道的類型。 |
'PolicyBased' 'RouteBased' |
快速入門範本
下列快速入門範本會部署此資源類型。
您可以使用目標作業來部署連線資源類型:
如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。
若要建立 Microsoft.Network/connections 資源,請將下列 Terraform 新增至您的範本。
resource "azapi_resource" "symbolicname" {
type = "Microsoft.Network/connections@2015-05-01-preview"
name = "string"
etag = "string"
location = "string"
tags = {
{customized property} = "string"
}
body = jsonencode({
properties = {
connectionStatus = "string"
connectionType = "string"
egressBytesTransferred = int
ingressBytesTransferred = int
localNetworkGateway2 = {
etag = "string"
location = "string"
properties = {
gatewayIpAddress = "string"
localNetworkAddressSpace = {
addressPrefixes = [
"string"
]
}
provisioningState = "string"
resourceGuid = "string"
}
tags = {
{customized property} = "string"
}
}
peer = {
id = "string"
}
provisioningState = "string"
resourceGuid = "string"
routingWeight = int
sharedKey = "string"
virtualNetworkGateway1 = {
etag = "string"
location = "string"
properties = {
enableBgp = bool
gatewayDefaultSite = {
id = "string"
}
gatewayType = "string"
ipConfigurations = [
{
etag = "string"
id = "string"
name = "string"
properties = {
privateIPAddress = "string"
privateIPAllocationMethod = "string"
provisioningState = "string"
publicIPAddress = {
id = "string"
}
subnet = {
id = "string"
}
}
}
]
provisioningState = "string"
resourceGuid = "string"
vpnType = "string"
}
tags = {
{customized property} = "string"
}
}
virtualNetworkGateway2 = {
etag = "string"
location = "string"
properties = {
enableBgp = bool
gatewayDefaultSite = {
id = "string"
}
gatewayType = "string"
ipConfigurations = [
{
etag = "string"
id = "string"
name = "string"
properties = {
privateIPAddress = "string"
privateIPAllocationMethod = "string"
provisioningState = "string"
publicIPAddress = {
id = "string"
}
subnet = {
id = "string"
}
}
}
]
provisioningState = "string"
resourceGuid = "string"
vpnType = "string"
}
tags = {
{customized property} = "string"
}
}
}
})
}
屬性值
AddressSpace
名字 |
描述 |
價值 |
addressPrefixes |
取得或設定在 CIDR 表示法中保留給此虛擬網路的位址區塊清單 |
string[] |
LocalNetworkGateway
名字 |
描述 |
價值 |
gatewayIpAddress |
局域網路閘道的IP位址。 |
字串 |
localNetworkAddressSpace |
局域網路網站位址空間 |
AddressSpace |
provisioningState |
取得或設定 LocalNetworkGateway 資源的布建狀態更新/刪除/失敗 |
字串 |
resourceGuid |
取得或設定 LocalNetworkGateway 資源的資源 GUID 屬性 |
字串 |
Microsoft.Network/connections
SubResource
VirtualNetworkGateway
名字 |
描述 |
價值 |
connectionStatus |
虛擬網路網關聯機狀態 |
'Connected' '聯機' 'NotConnected' 'Unknown' |
connectionType |
網關聯機類型 IPsec/Dedicated/VpnClient/Vnet2Vnet |
'ExpressRoute' 'IPsec' 'Vnet2Vnet' 'VPNClient' |
egressBytesTransferred |
在此連線中傳輸的輸出位元組 |
int |
ingressBytesTransferred |
在此連線中傳輸的輸入位元組 |
int |
localNetworkGateway2 |
一般資源資訊的通用類別 |
LocalNetworkGateway |
同輩 |
對等互連資源的參考。 |
SubResource |
provisioningState |
取得或設定 VirtualNetworkGatewayConnection 資源更新/刪除/失敗的布建狀態 |
字串 |
resourceGuid |
取得或設定 VirtualNetworkGatewayConnection 資源的資源 guid 屬性 |
字串 |
routingWeight |
路由權數。 |
int |
sharedKey |
IPsec 共用金鑰。 |
字串 |
virtualNetworkGateway1 |
一般資源資訊的通用類別 |
VirtualNetworkGateway |
virtualNetworkGateway2 |
一般資源資訊的通用類別 |
VirtualNetworkGateway |
VirtualNetworkGatewayIpConfiguration
名字 |
描述 |
價值 |
privateIPAddress |
取得或設定網路介面IP組態的 privateIPAddress |
字串 |
privateIPAllocationMethod |
取得或設定 PrivateIP 設定方法 (靜態/動態) |
'Dynamic' 'Static' |
provisioningState |
取得或設定 PublicIP 資源更新/刪除/失敗的布建狀態 |
字串 |
publicIPAddress |
取得或設定 PublicIP 資源的參考 |
SubResource |
子 |
取得或設定子網資源的參考 |
SubResource |
名字 |
描述 |
價值 |
enableBgp |
EnableBgp 旗標 |
bool |
gatewayDefaultSite |
取得或設定 LocalNetworkGateway 資源的參考,代表具有預設路由的局域網路網站。 如果移除現有的默認網站設定,請指派 Null 值。 |
SubResource |
gatewayType |
此虛擬網路閘道的類型。 |
'ExpressRoute' 'Vpn' |
ipConfigurations |
虛擬網路閘道的 IpConfigurations。 |
VirtualNetworkGatewayIpConfiguration[] |
provisioningState |
取得或設定 VirtualNetworkGateway 資源的布建狀態更新/刪除/失敗 |
字串 |
resourceGuid |
取得或設定 VirtualNetworkGateway 資源的資源 GUID 屬性 |
字串 |
vpnType |
此虛擬網路閘道的類型。 |
'PolicyBased' 'RouteBased' |