Skip to content

Commit

Permalink
Add ExpressRoute gateway resource (#3776)
Browse files Browse the repository at this point in the history
* Initial version

* Refactor connections.

* Update API version

* Add enum values.

* Addressed all comments.
  • Loading branch information
jjaviercv-msft authored and jianghaolu committed Sep 3, 2018
1 parent 3b1d5ec commit 57fc3df
Show file tree
Hide file tree
Showing 15 changed files with 1,037 additions and 56 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,10 @@
"state": "Enabled",
"vlanId": 200,
"gatewayManagerEtag": "",
"lastModifiedBy": "Customer"
"lastModifiedBy": "Customer",
"expressRouteConnection": {
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName/expressRouteConnections/connectionName"
}
}
}
},
Expand All @@ -54,7 +57,8 @@
"state": "Enabled",
"vlanId": 200,
"gatewayManagerEtag": "",
"lastModifiedBy": "Customer"
"lastModifiedBy": "Customer",
"expressRouteConnection": ""
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,55 +1,55 @@
{
"parameters": {
"circuitName": "circuitName",
"resourceGroupName": "rg1",
"api-version": "2018-08-01",
"subscriptionId": "subid",
"peeringName": "MicrosoftPeering"
},
"responses": {
"200": {
"name": "MicrosoftPeering",
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/expressRouteCircuits/circuitName/peerings/MicrosoftPeering",
"etag": "W/\"b2a25b98-2e6d-4d46-87f2-089de5f6fdf9\"",
"properties": {
"provisioningState": "Succeeded",
"peeringType": "MicrosoftPeering",
"azureASN": 12076,
"peerASN": 100,
"primaryPeerAddressPrefix": "123.0.0.0/30",
"secondaryPeerAddressPrefix": "123.0.0.4/30",
"primaryAzurePort": "A51-TEST-06GMR-CIS-1-PRI-A",
"secondaryAzurePort": "A51-TEST-06GMR-CIS-2-SEC-A",
"state": "Enabled",
"vlanId": 300,
"gatewayManagerEtag": "103",
"lastModifiedBy": "Customer",
"microsoftPeeringConfig": {
"advertisedPublicPrefixes": [
"123.1.0.0/24"
],
"advertisedCommunities": [],
"advertisedPublicPrefixesState": "ValidationNeeded",
"customerASN": 23,
"legacyMode": 0,
"routingRegistryName": "ARIN"
},
"ipv6PeeringConfig": {
"primaryPeerAddressPrefix": "3FFE:FFFF:0:CD30::/126",
"secondaryPeerAddressPrefix": "3FFE:FFFF:0:CD30::4/126",
"state": "Enabled",
"microsoftPeeringConfig": {
"advertisedPublicPrefixes": [
"3FFE:FFFF:0:CD31::/120"
],
"advertisedCommunities": [],
"advertisedPublicPrefixesState": "ValidationNeeded",
"customerASN": 23,
"legacyMode": 0,
"routingRegistryName": "ARIN"
}
"parameters": {
"circuitName": "circuitName",
"resourceGroupName": "rg1",
"api-version": "2018-08-01",
"subscriptionId": "subid",
"peeringName": "MicrosoftPeering"
},
"responses": {
"200": {
"name": "MicrosoftPeering",
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/expressRouteCircuits/circuitName/peerings/MicrosoftPeering",
"etag": "W/\"b2a25b98-2e6d-4d46-87f2-089de5f6fdf9\"",
"properties": {
"provisioningState": "Succeeded",
"peeringType": "MicrosoftPeering",
"azureASN": 12076,
"peerASN": 100,
"primaryPeerAddressPrefix": "123.0.0.0/30",
"secondaryPeerAddressPrefix": "123.0.0.4/30",
"primaryAzurePort": "A51-TEST-06GMR-CIS-1-PRI-A",
"secondaryAzurePort": "A51-TEST-06GMR-CIS-2-SEC-A",
"state": "Enabled",
"vlanId": 300,
"gatewayManagerEtag": "103",
"lastModifiedBy": "Customer",
"microsoftPeeringConfig": {
"advertisedPublicPrefixes": [
"123.1.0.0/24"
],
"advertisedCommunities": [],
"advertisedPublicPrefixesState": "ValidationNeeded",
"customerASN": 23,
"legacyMode": 0,
"routingRegistryName": "ARIN"
},
"ipv6PeeringConfig": {
"primaryPeerAddressPrefix": "3FFE:FFFF:0:CD30::/126",
"secondaryPeerAddressPrefix": "3FFE:FFFF:0:CD30::4/126",
"state": "Enabled",
"microsoftPeeringConfig": {
"advertisedPublicPrefixes": [
"3FFE:FFFF:0:CD31::/120"
],
"advertisedCommunities": [],
"advertisedPublicPrefixesState": "ValidationNeeded",
"customerASN": 23,
"legacyMode": 0,
"routingRegistryName": "ARIN"
}
}
}
}
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@
"legacyMode": 0,
"routingRegistryName": "ARIN"
}
}
},
"expressRouteConnection": ""
}
},
{
Expand All @@ -68,7 +69,10 @@
"state": "Enabled",
"vlanId": 200,
"gatewayManagerEtag": "103",
"lastModifiedBy": "Customer"
"lastModifiedBy": "Customer",
"expressRouteConnection": {
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName/expressRouteConnections/connectionName"
}
}
}
]
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"parameters": {
"expressRouteGatewayName": "expressRouteGatewayName",
"resourceGroupName": "resourceGroupName",
"api-version": "2018-08-01",
"subscriptionId": "subid",
"connectionName": "connectionName",
"putExpressRouteConnectionParameters": {
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName/expressRouteConnections/connectionName",
"name": "connectionName",
"properties": {
"routingWeight": 2,
"authorizationKey": "authorizationKey",
"expressRouteCircuitPeering": {
"id": "/subscriptions/subid2/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteCircuits/circuitName/peerings/AzurePrivatePeering"
}
}
}
},
"responses": {
"200": {
"body": {
"name": "connectionName",
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName/expressRouteConnections/connectionName",
"properties": {
"provisioningState": "Provisioned",
"expressRouteCircuitPeering": {
"id": "/subscriptions/subid2/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteCircuits/circuitName/peerings/AzurePrivatePeering"
},
"authorizationKey": "authorizationKey",
"routingWeight": 2
}
}
},
"201": {
"body": {
"name": "connectionName",
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName/expressRouteConnections/connectionName",
"properties": {
"provisioningState": "Provisioned",
"expressRouteCircuitPeering": {
"id": "/subscriptions/subid2/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteCircuits/circuitName/peerings/AzurePrivatePeering"
},
"authorizationKey": "authorizationKey",
"routingWeight": 2
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"parameters": {
"expressRouteGatewayName": "expressRouteGatewayName",
"resourceGroupName": "resourceGroupName",
"connectionName": "connectionName",
"api-version": "2018-08-01",
"subscriptionId": "subid"
},
"responses": {
"202": {},
"200": {},
"204": {}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"parameters": {
"expressRouteGatewayName": "expressRouteGatewayName",
"resourceGroupName": "resourceGroupName",
"api-version": "2018-08-01",
"subscriptionId": "subid",
"connectionName": "connectionName"
},
"responses": {
"200": {
"body": {
"name": "connectionName",
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName/expressRouteConnections/connectionName",
"properties": {
"provisioningState": "Provisioned",
"expressRouteCircuitPeering": {
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteCircuits/circuitName/peerings/AzurePrivatePeering"
},
"authorizationKey": "authorizationKey",
"routingWeight": 1
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"parameters": {
"api-version": "2018-08-01",
"resourceGroupName": "resourceGroupName",
"expressRouteGatewayName": "expressRouteGatewayName",
"subscriptionId": "subid"
},
"responses": {
"200": {
"body": {
"value": [
{
"name": "connectionName",
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName/expressRouteConnections/connectionName",
"properties": {
"provisioningState": "Provisioned",
"expressRouteCircuitPeering": {
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteCircuits/circuitName/peerings/AzurePrivatePeering"
},
"authorizationKey": "authorizationKey",
"routingWeight": 1
}
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
{
"parameters": {
"expressRouteGatewayName": "gateway-2",
"subscriptionId": "subid",
"resourceGroupName": "resourceGroupName",
"api-version": "2018-08-01",
"putExpressRouteGatewayParameters": {
"name": "gateway-2",
"type": "Microsoft.Network/expressRouteGateways",
"location": "westus",
"properties": {
"virtualHub": {
"id": "/subscriptions/subid/resourceGroups/resourceGroupId/providers/Microsoft.Network/virtualHubs/virtualHubName"
},
"autoScaleConfiguration": {
"bounds": {
"min": 3
}
}
}
}
},
"responses": {
"201": {
"body": {
"name": "gateway-2",
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/gateway-2",
"etag": "w/\\00000000-0000-0000-0000-000000000000\\",
"location": "westus",
"type": "Microsoft.Network/expressRouteGateways",
"properties": {
"provisioningState": "Succeeded",
"virtualHub": {
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/virtualHubs/virtualHubName"
},
"autoScaleConfiguration": {
"bounds": {
"min": 3
}
}
}
}
},
"200": {
"body": {
"name": "gateway-2",
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/gateway-2",
"etag": "w/\\00000000-0000-0000-0000-000000000000\\",
"location": "westus",
"type": "Microsoft.Network/expressRouteGateways",
"properties": {
"provisioningState": "Succeeded",
"virtualHub": {
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/virtualHubs/virtualHubName"
},
"autoScaleConfiguration": {
"bounds": {
"min": 3
}
}
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"parameters": {
"expressRouteGatewayName": "expressRouteGatewayName",
"resourceGroupName": "resourceGroupName",
"api-version": "2018-08-01",
"subscriptionId": "subid"
},
"responses": {
"202": {},
"200": {},
"204": {}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"parameters": {
"expressRouteGatewayName": "expressRouteGatewayName",
"resourceGroupName": "resourceGroupName",
"api-version": "2018-08-01",
"subscriptionId": "subid"
},
"responses": {
"200": {
"body": {
"name": "expressRouteGatewayName",
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/expressRouteGateways/expressRouteGatewayName",
"etag": "w/\\00000000-0000-0000-0000-000000000000\\",
"location": "westus",
"type": "Microsoft.Network/expressRouteGateways",
"properties": {
"provisioningState": "Succeeded",
"virtualHub": {
"id": "/subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.Network/virtualHubs/virtualHubName"
}
}
}
},
"404": {}
}
}
Loading

0 comments on commit 57fc3df

Please sign in to comment.