Set-AzApplicationGatewayListener

Modifies a TCP\TLS listener for an application gateway.

Syntax

Set-AzApplicationGatewayListener
   -ApplicationGateway <PSApplicationGateway>
   -Name <String>
   [-FrontendIPConfiguration <PSApplicationGatewayFrontendIPConfiguration>]
   [-FrontendPort <PSApplicationGatewayFrontendPort>]
   [-SslCertificate <PSApplicationGatewaySslCertificate>]
   [-SslProfile <PSApplicationGatewaySslProfile>]
   -Protocol <String>
   [-HostNames <String[]>]
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]
Set-AzApplicationGatewayListener
   -ApplicationGateway <PSApplicationGateway>
   -Name <String>
   [-FrontendIPConfigurationId <String>]
   [-FrontendPortId <String>]
   [-SslCertificateId <String>]
   [-SslProfileId <String>]
   -Protocol <String>
   [-HostNames <String[]>]
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]

Description

The Set-AzApplicationGatewayListener cmdlet modifies a TCP\TLS listener for an Azure application gateway.

Examples

Example 1: Set a TCP listener

$AppGw = Get-AzApplicationGateway -Name "ApplicationGateway01" -ResourceGroupName "ResourceGroup01"
$AppGw = Set-AzApplicationGatewayListener -ApplicationGateway $AppGw -Name "Listener01" -Protocol Tcp -FrontendIpConfiguration $FIP01 -FrontendPort 80

The first command gets the application gateway named ApplicationGateway01 that belongs to the resource group named ResourceGroup01 and stores it in the $AppGw variable. The second command sets the listener for the gateway to use the front-end configuration stored in $FIP01 with the Tcp protocol on port 80.

Example 2: Add a TLS listener with SSL Certificate

$AppGw = Get-AzApplicationGateway -Name "ApplicationGateway01" -ResourceGroupName "ResourceGroup01"
$AppGw = Set-AzApplicationGatewayListener -ApplicationGateway $AppGw -Name "Listener01" -Protocol "Tls" -FrontendIpConfiguration $FIP01 -FrontendPort $FP01 -SslCertificate $SSLCert01

The first command gets the application gateway and stores it in the $AppGw variable. The second command adds the listener, which uses the Tls protocol, with SSL Certificates , to the application gateway.

Parameters

-ApplicationGateway

The applicationGateway

Type:PSApplicationGateway
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with Azure.

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-FrontendIPConfiguration

Application gateway FrontendIPConfiguration

Type:PSApplicationGatewayFrontendIPConfiguration
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-FrontendIPConfigurationId

ID of the application gateway FrontendIPConfiguration

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-FrontendPort

Application gateway FrontendPort

Type:PSApplicationGatewayFrontendPort
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-FrontendPortId

ID of the application gateway FrontendPort

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-HostNames

Host names

Type:String[]
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Name

The name of the Listener

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-Protocol

Protocol

Type:String
Accepted values:TCP, TLS
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-SslCertificate

Application gateway SslCertificate

Type:PSApplicationGatewaySslCertificate
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-SslCertificateId

ID of the application gateway SslCertificate

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-SslProfile

SslProfile

Type:PSApplicationGatewaySslProfile
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-SslProfileId

SslProfileId

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

PSApplicationGateway

Outputs

PSApplicationGateway