Skip to content

Commit fe0e81b

Browse files
author
Piyush Mishra
committed
Pev6 changes
1 parent 8ea4a34 commit fe0e81b

File tree

4 files changed

+27
-1
lines changed

4 files changed

+27
-1
lines changed

src/Network/Network/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
--->
2020

2121
## Upcoming Release
22+
* Added `-IpVersionType` parameter to `New-AzPrivateEndpoint` cmdlet to specify the IP version type for private IPs of the private endpoint. Allowed values are IPv4, IPv6, or DualStack.
2223

2324
## Version 7.24.0
2425
* Added support for `RecordType` property in `New-AzNetworkWatcherFlowLog` and `Set-AzNetworkWatcherFlowLog` cmdlets.

src/Network/Network/Models/PSPrivateEndpoint.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ public partial class PSPrivateEndpoint : PSTopLevelResource
3737

3838
public string CustomNetworkInterfaceName { get; internal set; }
3939

40+
public string IpVersionType { get; set; }
41+
4042
[JsonIgnore]
4143
public string SubnetText
4244
{

src/Network/Network/PrivateEndpoint/NewAzurePrivateEndpointCommand.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,10 @@ public class NewAzurePrivateEndpoint : PrivateEndpointBaseCmdlet
101101
[Parameter(Mandatory = false, HelpMessage = "The custom network interface name")]
102102
public string CustomNetworkInterfaceName { get; set; }
103103

104+
[Parameter(Mandatory = false, HelpMessage = "Specifies the IP version type for the private IPs of the private endpoint. If not defined, this defaults to IPv4. Allowed values are IPv4, IPv6, or DualStack.")]
105+
[ValidateSet("IPv4", "IPv6", "DualStack", IgnoreCase = true)]
106+
public string IpVersionType { get; set; }
107+
104108
private PSPrivateEndpoint CreatePSPrivateEndpoint()
105109
{
106110
var psPrivateEndpoint = new PSPrivateEndpoint
@@ -138,6 +142,10 @@ private PSPrivateEndpoint CreatePSPrivateEndpoint()
138142
{
139143
psPrivateEndpoint.CustomNetworkInterfaceName = this.CustomNetworkInterfaceName;
140144
}
145+
if (!string.IsNullOrEmpty(this.IpVersionType))
146+
{
147+
psPrivateEndpoint.IpVersionType = this.IpVersionType;
148+
}
141149

142150

143151
var peModel = NetworkResourceManagerProfile.Mapper.Map<MNM.PrivateEndpoint>(psPrivateEndpoint);

src/Network/Network/help/New-AzPrivateEndpoint.md

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ New-AzPrivateEndpoint -Name <String> -ResourceGroupName <String> -Location <Stri
1717
-PrivateLinkServiceConnection <PSPrivateLinkServiceConnection[]> [-ByManualRequest] [-EdgeZone <String>]
1818
[-Tag <Hashtable>] [-Force] [-AsJob] [-ApplicationSecurityGroup <PSApplicationSecurityGroup[]>]
1919
[-IpConfiguration <PSPrivateEndpointIPConfiguration[]>] [-CustomNetworkInterfaceName <String>]
20-
[-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm]
20+
[-IpVersionType <String>] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm]
2121
[<CommonParameters>]
2222
```
2323

@@ -165,6 +165,21 @@ Accept pipeline input: False
165165
Accept wildcard characters: False
166166
```
167167
168+
### -IpVersionType
169+
Specifies the IP version type for the private IPs of the private endpoint. If not defined, this defaults to IPv4. Allowed values are IPv4, IPv6, or DualStack.
170+
171+
```yaml
172+
Type: System.String
173+
Parameter Sets: (All)
174+
Aliases:
175+
176+
Required: False
177+
Position: Named
178+
Default value: None
179+
Accept pipeline input: False
180+
Accept wildcard characters: False
181+
```
182+
168183
### -Location
169184
170185
Specifies a location for the private endpoint. Use [Get-AzLocation](/powershell/module/az.resources/get-azlocation)

0 commit comments

Comments
 (0)