< Back
New-AzureRmVirtualNetworkGatewayConnection
Post
NAME New-AzureRmVirtualNetworkGatewayConnection
SYNOPSIS
SYNTAX
New-AzureRmVirtualNetworkGatewayConnection [-AsJob] [-AuthorizationKey <String>] -ConnectionType {IPsec | Vnet2Vnet | ExpressRoute | VPNClient}
[-DefaultProfile <IAzureContextContainer>] [-EnableBgp <Boolean>] [-Force] [-IpsecPolicies
<System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSIpsecPolicy]>] [-LocalNetworkGateway2 <PSLocalNetworkGateway>]
-Location <String> -Name <String> [-Peer <PSPeering>] -ResourceGroupName <String> [-RoutingWeight <Int32>] [-SharedKey <String>] [-Tag
<Hashtable>] [-UsePolicyBasedTrafficSelectors <Boolean>] -VirtualNetworkGateway1 <PSVirtualNetworkGateway> [-VirtualNetworkGateway2
<PSVirtualNetworkGateway>] [-Confirm] [-WhatIf] [<CommonParameters>]
New-AzureRmVirtualNetworkGatewayConnection [-AsJob] [-AuthorizationKey <String>] -ConnectionType {IPsec | Vnet2Vnet | ExpressRoute | VPNClient}
[-DefaultProfile <IAzureContextContainer>] [-EnableBgp <Boolean>] [-Force] [-IpsecPolicies
<System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSIpsecPolicy]>] [-LocalNetworkGateway2 <PSLocalNetworkGateway>]
-Location <String> -Name <String> [-PeerId <String>] -ResourceGroupName <String> [-RoutingWeight <Int32>] [-SharedKey <String>] [-Tag <Hashtable>]
[-UsePolicyBasedTrafficSelectors <Boolean>] -VirtualNetworkGateway1 <PSVirtualNetworkGateway> [-VirtualNetworkGateway2 <PSVirtualNetworkGateway>]
[-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
PARAMETERS
-AsJob [<SwitchParameter>]
Run cmdlet in the background
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-AuthorizationKey <String>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ConnectionType <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-EnableBgp <Boolean>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Force [<SwitchParameter>]
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-IpsecPolicies <System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSIpsecPolicy]>
A list of IPSec policies.
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-LocalNetworkGateway2 <PSLocalNetworkGateway>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Location <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Name <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Peer <PSPeering>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-PeerId <String>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ResourceGroupName <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-RoutingWeight <Int32>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-SharedKey <String>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Tag <Hashtable>
Key-value pairs in the form of a hash table. For example:
@{key0="value0";key1=$null;key2="value2"}
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-UsePolicyBasedTrafficSelectors <Boolean>
Use policy-based traffic selectors for a S2S connection
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-VirtualNetworkGateway1 <PSVirtualNetworkGateway>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-VirtualNetworkGateway2 <PSVirtualNetworkGateway>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
None
This cmdlet does not accept any input.
OUTPUTS
Microsoft.Azure.Commands.Network.Models.PSVirtualNetworkGatewayConnection
NOTES
1:
New-AzureRmVirtualNetworkGatewayConnection -Name conn-client-1 -ResourceGroupName $RG1 -VirtualNetworkGateway1 $vnetgw1 -VirtualNetworkGateway2
$vnetgw2 -Location $loc1 -ConnectionType Vnet2Vnet -SharedKey 'a1b2c3d4e5'
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... connection
Get-AzureRmVirtualNetworkGatewayConnection
Remove-AzureRmVirtualNetworkGatewayConnection
Reset-AzureRmVirtualNetworkGatewayConnectionSharedKey
SYNOPSIS
SYNTAX
New-AzureRmVirtualNetworkGatewayConnection [-AsJob] [-AuthorizationKey <String>] -ConnectionType {IPsec | Vnet2Vnet | ExpressRoute | VPNClient}
[-DefaultProfile <IAzureContextContainer>] [-EnableBgp <Boolean>] [-Force] [-IpsecPolicies
<System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSIpsecPolicy]>] [-LocalNetworkGateway2 <PSLocalNetworkGateway>]
-Location <String> -Name <String> [-Peer <PSPeering>] -ResourceGroupName <String> [-RoutingWeight <Int32>] [-SharedKey <String>] [-Tag
<Hashtable>] [-UsePolicyBasedTrafficSelectors <Boolean>] -VirtualNetworkGateway1 <PSVirtualNetworkGateway> [-VirtualNetworkGateway2
<PSVirtualNetworkGateway>] [-Confirm] [-WhatIf] [<CommonParameters>]
New-AzureRmVirtualNetworkGatewayConnection [-AsJob] [-AuthorizationKey <String>] -ConnectionType {IPsec | Vnet2Vnet | ExpressRoute | VPNClient}
[-DefaultProfile <IAzureContextContainer>] [-EnableBgp <Boolean>] [-Force] [-IpsecPolicies
<System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSIpsecPolicy]>] [-LocalNetworkGateway2 <PSLocalNetworkGateway>]
-Location <String> -Name <String> [-PeerId <String>] -ResourceGroupName <String> [-RoutingWeight <Int32>] [-SharedKey <String>] [-Tag <Hashtable>]
[-UsePolicyBasedTrafficSelectors <Boolean>] -VirtualNetworkGateway1 <PSVirtualNetworkGateway> [-VirtualNetworkGateway2 <PSVirtualNetworkGateway>]
[-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
PARAMETERS
-AsJob [<SwitchParameter>]
Run cmdlet in the background
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-AuthorizationKey <String>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ConnectionType <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-EnableBgp <Boolean>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Force [<SwitchParameter>]
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-IpsecPolicies <System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSIpsecPolicy]>
A list of IPSec policies.
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-LocalNetworkGateway2 <PSLocalNetworkGateway>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Location <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Name <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Peer <PSPeering>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-PeerId <String>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ResourceGroupName <String>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-RoutingWeight <Int32>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-SharedKey <String>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Tag <Hashtable>
Key-value pairs in the form of a hash table. For example:
@{key0="value0";key1=$null;key2="value2"}
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-UsePolicyBasedTrafficSelectors <Boolean>
Use policy-based traffic selectors for a S2S connection
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-VirtualNetworkGateway1 <PSVirtualNetworkGateway>
Required? true
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-VirtualNetworkGateway2 <PSVirtualNetworkGateway>
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
None
This cmdlet does not accept any input.
OUTPUTS
Microsoft.Azure.Commands.Network.Models.PSVirtualNetworkGatewayConnection
NOTES
1:
New-AzureRmVirtualNetworkGatewayConnection -Name conn-client-1 -ResourceGroupName $RG1 -VirtualNetworkGateway1 $vnetgw1 -VirtualNetworkGateway2
$vnetgw2 -Location $loc1 -ConnectionType Vnet2Vnet -SharedKey 'a1b2c3d4e5'
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... connection
Get-AzureRmVirtualNetworkGatewayConnection
Remove-AzureRmVirtualNetworkGatewayConnection
Reset-AzureRmVirtualNetworkGatewayConnectionSharedKey