שתף באמצעות


az network front-door rules-engine rule action

Note

This reference is part of the front-door extension for the Azure CLI (version 2.57.0 or higher). The extension will automatically install the first time you run an az network front-door rules-engine rule action command. Learn more about extensions.

Manage Rules Engine actions for Front Door.

Commands

Name Description Type Status
az network front-door rules-engine rule action add

Add an action to a Rules Engine rule.

Extension GA
az network front-door rules-engine rule action list

Show all actions that apply for a Rules Engine rule.

Extension GA
az network front-door rules-engine rule action remove

Remove an action from a Rules Engine rule.

Extension GA

az network front-door rules-engine rule action add

Add an action to a Rules Engine rule.

az network front-door rules-engine rule action add --action-type {ForwardRouteOverride, RedirectRouteOverride, RequestHeader, ResponseHeader}
                                                   --front-door-name
                                                   --name
                                                   --resource-group
                                                   --rules-engine-name
                                                   [--backend-pool]
                                                   [--cache-duration]
                                                   [--caching {Disabled, Enabled}]
                                                   [--custom-forwarding-path]
                                                   [--custom-fragment]
                                                   [--custom-host]
                                                   [--custom-path]
                                                   [--custom-query-string]
                                                   [--dynamic-compression {Disabled, Enabled}]
                                                   [--forwarding-protocol {HttpOnly, HttpsOnly, MatchRequest}]
                                                   [--header-action {Append, Delete, Overwrite}]
                                                   [--header-name]
                                                   [--header-value]
                                                   [--query-parameter-strip-directive {StripAll, StripAllExcept, StripNone, StripOnly}]
                                                   [--query-parameters]
                                                   [--redirect-protocol {HttpOnly, HttpsOnly, MatchRequest}]
                                                   [--redirect-type {Found, Moved, PermanentRedirect, TemporaryRedirect}]

Required Parameters

--action-type

Action type to apply for a rule.

Accepted values: ForwardRouteOverride, RedirectRouteOverride, RequestHeader, ResponseHeader
--front-door-name -f

Name of the Front Door.

--name -n

Name of the rule.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--rules-engine-name -r

Name of the Rules Engine.

Optional Parameters

--backend-pool

Name or ID of a backend pool.

--cache-duration

The duration for which the content needs to be cached. Allowed format is ISO 8601 duration.

--caching

Whether to enable caching for this route.

Accepted values: Disabled, Enabled
--custom-forwarding-path

Custom path used to rewrite resource paths matched by this rule. Leave empty to use incoming path.

--custom-fragment

Fragment to add to the redirect URL. Fragment is the part of the URL that comes after #. Do not include the #.

--custom-host

Host to redirect. Leave empty to use use the incoming host as the destination host.

--custom-path

The full path to redirect. Path cannot be empty and must start with /. Leave empty to use the incoming path as destination path.

--custom-query-string

The set of query strings to be placed in the redirect URL. Setting this value would replace any existing query string; leave empty to preserve the incoming query string. Query string must be in = format. The first ? and & will be added automatically so do not include them in the front, but do separate multiple query strings with &.

--dynamic-compression

Use dynamic compression for cached content.

Accepted values: Disabled, Enabled
--forwarding-protocol

Protocol to use for forwarding traffic.

Accepted values: HttpOnly, HttpsOnly, MatchRequest
--header-action

Header action type for the requests.

Accepted values: Append, Delete, Overwrite
--header-name

Name of the header to modify.

--header-value

Value of the header.

--query-parameter-strip-directive

Treatment of URL query terms when forming the cache key.

Accepted values: StripAll, StripAllExcept, StripNone, StripOnly
--query-parameters

Query parameters to include or exclude (comma separated) when using query-parameter-strip-directive type StripAllExcept or StripOnly respectively.

--redirect-protocol

The protocol of the destination to where the traffic is redirected.

Accepted values: HttpOnly, HttpsOnly, MatchRequest
Default value: MatchRequest
--redirect-type

The redirect type the rule will use when redirecting traffic.

Accepted values: Found, Moved, PermanentRedirect, TemporaryRedirect
Default value: Moved
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az network front-door rules-engine rule action list

Show all actions that apply for a Rules Engine rule.

az network front-door rules-engine rule action list --front-door-name
                                                    --name
                                                    --resource-group
                                                    --rules-engine-name

Required Parameters

--front-door-name -f

Name of the Front Door.

--name -n

Name of the rule.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--rules-engine-name -r

Name of the Rules Engine.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az network front-door rules-engine rule action remove

Remove an action from a Rules Engine rule.

az network front-door rules-engine rule action remove --action-type {ForwardRouteOverride, RedirectRouteOverride, RequestHeader, ResponseHeader}
                                                      --front-door-name
                                                      --name
                                                      --resource-group
                                                      --rules-engine-name
                                                      [--index]

Required Parameters

--action-type

Action type to apply for a rule.

Accepted values: ForwardRouteOverride, RedirectRouteOverride, RequestHeader, ResponseHeader
--front-door-name -f

Name of the Front Door.

--name -n

Name of the rule.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--rules-engine-name -r

Name of the Rules Engine.

Optional Parameters

--index

0-based index of the request or response header action to remove. Index parameter is not required for "ForwardRouteOverride" or "RedirectRouteOverride" action remove.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.