New-AzApplicationGatewayIPConfiguration
Creates an IP configuration for an application gateway.
Syntax
SetByResourceId
New-AzApplicationGatewayIPConfiguration
-Name <String>
[-SubnetId <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
SetByResource
New-AzApplicationGatewayIPConfiguration
-Name <String>
[-Subnet <PSSubnet>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
The New-AzApplicationGatewayIPConfiguration cmdlet creates an IP configuration for an application gateway. The IP configuration contains the subnet in which application gateway is deployed.
Examples
Example 1: Create an IP configuration for an application gateway.
$VNet = Get-AzVirtualNetwork -Name "VNet01" -ResourceGroupName "ResourceGroup01"
$Subnet = Get-AzVirtualNetworkSubnetConfig -Name "Subnet01" -VirtualNetwork $VNet
$GatewayIpConfig = New-AzApplicationGatewayIPConfiguration -Name "AppGwSubnet01" -Subnet $Subnet
The first command gets a virtual network named VNet01 that belongs to the resource group named ResourceGroup01. The second command gets the subnet configuration for the subnet that the virtual network in the previous command belongs to, and stores it in the $Subnet variable. The third command creates the IP configuration using $Subnet.
Parameters
-DefaultProfile
The credentials, account, tenant, and subscription used for communication with azure.
Parameter properties
Type: | IAzureContextContainer |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Aliases: | AzContext, AzureRmContext, AzureCredential |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Name
Specifies the name of the IP configuration to create.
Parameter properties
Type: | String |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | True |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Subnet
Specifies the subnet object. This is the subnet in which the application gateway is deployed.
Parameter properties
Type: | PSSubnet |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
SetByResource
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-SubnetId
Specifies the subnet ID. This is the subnet in which the application gateway would be deployed.
Parameter properties
Type: | String |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
SetByResourceId
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.