Skip to content

Commit b4ac9f5

Browse files
Henry Chenisra-fel
andauthored
Expose IP Configurations for Microsoft.Network\VpnGateways (#12315)
* new ip configurations * changelog * help file * Update src/Network/Network/Models/Cortex/PSVpnGateway.cs As per PR suggestion Co-authored-by: Yeming Liu <[email protected]> Co-authored-by: Yeming Liu <[email protected]>
1 parent 7bf263d commit b4ac9f5

File tree

5 files changed

+35
-1
lines changed

5 files changed

+35
-1
lines changed

src/Network/Network/ChangeLog.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@
3030
- `Get-AzVirtualRouterPeer`
3131
- `Remove-AzVirtualRouterPeer`
3232
* Added RemoteBgpCommunities property to the VirtualNetwork Peering Resource
33+
* Modified the warning message for `New-AzLoadBalancerFrontendIpConfig`, `New-AzPublicIpAddress` and `New-AzPublicIpPrefix`.
34+
* Added VpnGatewayIpConfigurations to `Get-AzVpnGateway` output
3335

3436
## Version 3.3.0
3537
* Added support for AddressPrefixType parameter to `Remove-AzExpressRouteCircuitConnectionConfig`

src/Network/Network/Common/NetworkResourceManagerProfile.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1088,6 +1088,7 @@ private static void Initialize()
10881088
cfg.CreateMap<CNM.PSVirtualHubRouteTable, MNM.VirtualHubRouteTableV2>();
10891089
cfg.CreateMap<CNM.PSVirtualHubRoute, MNM.VirtualHubRouteV2>();
10901090
cfg.CreateMap<CNM.PSVpnGateway, MNM.VpnGateway>();
1091+
cfg.CreateMap<CNM.PSVpnGatewayIpConfiguration, MNM.VpnGatewayIpConfiguration>();
10911092
cfg.CreateMap<CNM.PSVpnSiteLinkConnection, MNM.VpnSiteLinkConnection>();
10921093
cfg.CreateMap<CNM.PSVpnSiteLink, MNM.VpnSiteLink>();
10931094
cfg.CreateMap<CNM.PSVpnLinkProviderProperties, MNM.VpnLinkProviderProperties>();
@@ -1121,6 +1122,7 @@ private static void Initialize()
11211122
cfg.CreateMap<MNM.VirtualHubRouteTableV2, CNM.PSVirtualHubRouteTable>();
11221123
cfg.CreateMap<MNM.VirtualHubRouteV2, CNM.PSVirtualHubRoute>();
11231124
cfg.CreateMap<MNM.VpnGateway, CNM.PSVpnGateway>();
1125+
cfg.CreateMap<MNM.VpnGatewayIpConfiguration, CNM.PSVpnGatewayIpConfiguration>();
11241126
cfg.CreateMap<MNM.VpnConnection, CNM.PSVpnConnection>();
11251127
cfg.CreateMap<MNM.VpnSite, CNM.PSVpnSite>().AfterMap((src, dest) =>
11261128
{

src/Network/Network/Models/Cortex/PSVpnGateway.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,7 @@ public class PSVpnGateway : PSTopLevelResource
3131

3232
[Ps1Xml(Label = "Provisioning State", Target = ViewControl.Table)]
3333
public string ProvisioningState { get; set; }
34+
35+
public List<PSVpnGatewayIpConfiguration> IpConfigurations { get; set;}
3436
}
35-
}
37+
}
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// ----------------------------------------------------------------------------------
2+
//
3+
// Copyright Microsoft Corporation
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
// Unless required by applicable law or agreed to in writing, software
9+
// distributed under the License is distributed on an "AS IS" BASIS,
10+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
// See the License for the specific language governing permissions and
12+
// limitations under the License.
13+
// ----------------------------------------------------------------------------------
14+
15+
namespace Microsoft.Azure.Commands.Network.Models
16+
{
17+
public class PSVpnGatewayIpConfiguration
18+
{
19+
public string Id { get; set; }
20+
21+
public string PublicIpAddress { get; set; }
22+
23+
public string PrivateIpAddress { get; set; }
24+
}
25+
}

src/Network/Network/help/Get-AzVpnGateway.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ Location : West US
4444
VpnGatewayScaleUnit : 2
4545
VirtualHub : /subscriptions/{subscriptionId}/resourceGroups/Ali_pS_Test/providers/Microsoft.Network/virtualHubs/westushub
4646
BgpSettings : {}
47+
IpConfigurations : {Instance0, Instance1}
4748
Type : Microsoft.Network/vpnGateways
4849
ProvisioningState : Succeeded
4950
```
@@ -65,6 +66,7 @@ Location : West US
6566
VpnGatewayScaleUnit : 2
6667
VirtualHub : /subscriptions/{subscriptionId}/resourceGroups/Ali_pS_Test/providers/Microsoft.Network/virtualHubs/westushub
6768
BgpSettings : {}
69+
IpConfigurations : {Instance0, Instance1}
6870
Type : Microsoft.Network/vpnGateways
6971
ProvisioningState : Succeeded
7072
@@ -75,6 +77,7 @@ Location : West US
7577
VpnGatewayScaleUnit : 2
7678
VirtualHub : /subscriptions/{subscriptionId}/resourceGroups/Ali_pS_Test/providers/Microsoft.Network/virtualHubs/westushub
7779
BgpSettings : {}
80+
IpConfigurations : {Instance0, Instance1}
7881
Type : Microsoft.Network/vpnGateways
7982
ProvisioningState : Succeeded
8083
```

0 commit comments

Comments
 (0)