New-AzApplicationGatewayRequestRoutingRule
Creates a request routing rule for an application gateway.
Syntax
New-AzApplicationGatewayRequestRoutingRule
-Name <String>
-RuleType <String>
[-Priority <Int32>]
[-BackendHttpSettingsId <String>]
[-HttpListenerId <String>]
[-BackendAddressPoolId <String>]
[-UrlPathMapId <String>]
[-RewriteRuleSetId <String>]
[-RedirectConfigurationId <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
New-AzApplicationGatewayRequestRoutingRule
-Name <String>
-RuleType <String>
[-Priority <Int32>]
[-BackendHttpSettings <PSApplicationGatewayBackendHttpSettings>]
[-HttpListener <PSApplicationGatewayHttpListener>]
[-BackendAddressPool <PSApplicationGatewayBackendAddressPool>]
[-UrlPathMap <PSApplicationGatewayUrlPathMap>]
[-RewriteRuleSet <PSApplicationGatewayRewriteRuleSet>]
[-RedirectConfiguration <PSApplicationGatewayRedirectConfiguration>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
The Add-AzApplicationGatewayRequestRoutingRule cmdlet creates a request routing rule for an Azure application gateway.
Examples
Example 1: Create a request routing rule for an application gateway
$Rule = New-AzApplicationGatewayRequestRoutingRule -Name "Rule01" -RuleType Basic -Priority 100 -BackendHttpSettings $Setting -HttpListener $Listener -BackendAddressPool $Pool
This command creates a basic request routing rule named Rule01 and stores the result in the variable named $Rule.
Parameters
-BackendAddressPool
Specifies the back-end address pool, as an object, for the request routing rule to create.
Type: | PSApplicationGatewayBackendAddressPool |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-BackendAddressPoolId
Specifies the back-end address pool ID of the request routing rule to create.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-BackendHttpSettings
Specifies the back-end HTTP settings, as an object, for the request routing rule to create.
Type: | PSApplicationGatewayBackendHttpSettings |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-BackendHttpSettingsId
Specifies the back-end HTTP settings ID of the request routing rule to create.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
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 |
-HttpListener
Specifies the back-end HTTP listener for the request routing rule to create.
Type: | PSApplicationGatewayHttpListener |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-HttpListenerId
Specifies the backend HTTP listener ID for the request routing rule to create.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Name
Specifies the name of the request routing rule that this cmdlet creates.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Priority
The priority of the rule
Type: | Nullable<T>[Int32] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RedirectConfiguration
Application gateway RedirectConfiguration
Type: | PSApplicationGatewayRedirectConfiguration |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RedirectConfigurationId
ID of the application gateway RedirectConfiguration
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RewriteRuleSet
Application gateway RewriteRuleSet
Type: | PSApplicationGatewayRewriteRuleSet |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RewriteRuleSetId
ID of the application gateway RewriteRuleSet
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RuleType
Specifies type of the request routing rule.
Type: | String |
Accepted values: | Basic, PathBasedRouting |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-UrlPathMap
Type: | PSApplicationGatewayUrlPathMap |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-UrlPathMapId
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
None
Outputs
PSApplicationGatewayRequestRoutingRule
Related Links
Azure PowerShell