Set-AzApplicationGatewayHttpListener
Modifies an HTTP listener for an application gateway.
Note
This is the previous version of our documentation. Please consult the most recent version for up-to-date information.
Syntax
Set-AzApplicationGatewayHttpListener
-ApplicationGateway <PSApplicationGateway>
-Name <String>
[-FrontendIPConfigurationId <String>]
[-FrontendPortId <String>]
[-SslCertificateId <String>]
[-FirewallPolicyId <String>]
[-SslProfileId <String>]
[-HostName <String>]
[-HostNames <String[]>]
[-RequireServerNameIndication <String>]
-Protocol <String>
[-CustomErrorConfiguration <PSApplicationGatewayCustomError[]>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Set-AzApplicationGatewayHttpListener
-ApplicationGateway <PSApplicationGateway>
-Name <String>
[-FrontendIPConfiguration <PSApplicationGatewayFrontendIPConfiguration>]
[-FrontendPort <PSApplicationGatewayFrontendPort>]
[-FirewallPolicy <PSApplicationGatewayWebApplicationFirewallPolicy>]
[-SslCertificate <PSApplicationGatewaySslCertificate>]
[-SslProfile <PSApplicationGatewaySslProfile>]
[-HostName <String>]
[-HostNames <String[]>]
[-RequireServerNameIndication <String>]
-Protocol <String>
[-CustomErrorConfiguration <PSApplicationGatewayCustomError[]>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
The Set-AzApplicationGatewayHttpListener cmdlet modifies an HTTP listener for an Azure application gateway.
Examples
Example 1: Set an HTTP listener
PS C:\>$AppGw = Get-AzApplicationGateway -Name "ApplicationGateway01" -ResourceGroupName "ResourceGroup01"
PS C:\> $AppGw = Set-AzApplicationGatewayHttpListener -ApplicationGateway $AppGw -Name "Listener01" -Protocol Http -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 HTTP listener for the gateway to use the front-end configuration stored in $FIP01 with the HTTP protocol on port 80.
Example 2: Add a HTTPS listener with SSL and HostNames
PS C:\>$AppGw = Get-AzApplicationGateway -Name "ApplicationGateway01" -ResourceGroupName "ResourceGroup01"
PS C:\> $AppGw = Set-AzApplicationGatewayHttpListener -ApplicationGateway $AppGw -Name "Listener01" -Protocol "Https" -FrontendIpConfiguration $FIP01 -FrontendPort $FP01 -SslCertificate $SSLCert01 -HostNames "*.contoso.com,www.microsoft.com"
The first command gets the application gateway and stores it in the $AppGw variable. The second command adds the listener, which uses the HTTPS protocol, with SSL Certificates and HostNames, to the application gateway.
Parameters
Specifies the application gateway with which this cmdlet associates the HTTP listener.
| Type: | PSApplicationGateway |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Customer error of an application gateway
| Type: | PSApplicationGatewayCustomError[] |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The credentials, account, tenant, and subscription used for communication with azure.
| Type: | IAzureContextContainer |
| Aliases: | AzContext, AzureRmContext, AzureCredential |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
FirewallPolicy
| Type: | PSApplicationGatewayWebApplicationFirewallPolicy |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
FirewallPolicyId
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the front-end IP address of the application gateway.
| Type: | PSApplicationGatewayFrontendIPConfiguration |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the ID of the front-end IP address of the application gateway.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the application gateway front-end port.
| Type: | PSApplicationGatewayFrontendPort |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the application gateway front-end port ID.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the host name that this cmdlet sends the HTTP listener to.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Host names
| Type: | String[] |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the name of the HTTP listener.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the protocol that the HTTP listener uses. The acceptable values for this parameter are:
- Http
- Https
| Type: | String |
| Accepted values: | Http, Https |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies whether the cmdlet requires a server name indication. The acceptable values for this parameter are: true or false.
| Type: | String |
| Accepted values: | true, false |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the SSL certificate of the HTTP listener.
| Type: | PSApplicationGatewaySslCertificate |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the Secure Socket Layer (SSL) certificate ID of the HTTP listener.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
SslProfile
| Type: | PSApplicationGatewaySslProfile |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
SslProfileId
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |