policies
Creates, updates, deletes, gets or lists a policies
resource.
Overview
Name | policies |
Type | Resource |
Id | azure.front_door.policies |
Fields
- vw_policies
- policies
Name | Datatype | Description |
---|---|---|
id | text | Resource ID. |
name | text | Resource name. |
custom_rules | text | field from the properties object |
etag | text | Gets a unique read-only string that changes whenever the resource is updated. |
frontend_endpoint_links | text | field from the properties object |
location | text | Resource location. |
managed_rules | text | field from the properties object |
policyName | text | field from the properties object |
policy_settings | text | field from the properties object |
provisioning_state | text | field from the properties object |
resourceGroupName | text | field from the properties object |
resource_state | text | field from the properties object |
routing_rule_links | text | field from the properties object |
security_policy_links | text | field from the properties object |
sku | text | The pricing tier of the web application firewall policy. |
subscriptionId | text | field from the properties object |
tags | text | Resource tags. |
type | text | Resource type. |
Name | Datatype | Description |
---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
etag | string | Gets a unique read-only string that changes whenever the resource is updated. |
location | string | Resource location. |
properties | object | Defines web application firewall policy properties. |
sku | object | The pricing tier of the web application firewall policy. |
tags | object | Resource tags. |
type | string | Resource type. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | policyName, resourceGroupName, subscriptionId | Retrieve protection policy with specified name within a resource group. |
list | SELECT | resourceGroupName, subscriptionId | Lists all of the protection policies within a resource group. |
list_by_subscription | SELECT | subscriptionId | Lists all of the protection policies within a subscription. |
create_or_update | INSERT | policyName, resourceGroupName, subscriptionId | Create or update policy with specified rule set name within a resource group. |
delete | DELETE | policyName, resourceGroupName, subscriptionId | Deletes Policy |
update | UPDATE | policyName, resourceGroupName, subscriptionId | Patch a specific frontdoor webApplicationFirewall policy for tags update under the specified subscription and resource group. |
SELECT
examples
Lists all of the protection policies within a subscription.
- vw_policies
- policies
SELECT
id,
name,
custom_rules,
etag,
frontend_endpoint_links,
location,
managed_rules,
policyName,
policy_settings,
provisioning_state,
resourceGroupName,
resource_state,
routing_rule_links,
security_policy_links,
sku,
subscriptionId,
tags,
type
FROM azure.front_door.vw_policies
WHERE subscriptionId = '{{ subscriptionId }}';
SELECT
id,
name,
etag,
location,
properties,
sku,
tags,
type
FROM azure.front_door.policies
WHERE subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new policies
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.front_door.policies (
policyName,
resourceGroupName,
subscriptionId,
properties,
etag,
sku,
location,
tags
)
SELECT
'{{ policyName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ properties }}',
'{{ etag }}',
'{{ sku }}',
'{{ location }}',
'{{ tags }}'
;
- name: your_resource_model_name
props:
- name: properties
value:
- name: policySettings
value:
- name: enabledState
value: string
- name: mode
value: string
- name: redirectUrl
value: string
- name: customBlockResponseStatusCode
value: integer
- name: customBlockResponseBody
value: string
- name: requestBodyCheck
value: string
- name: javascriptChallengeExpirationInMinutes
value: integer
- name: logScrubbing
value:
- name: state
value: string
- name: scrubbingRules
value:
- - name: matchVariable
value: string
- name: selectorMatchOperator
value: string
- name: selector
value: string
- name: state
value: string
- name: customRules
value:
- name: rules
value:
- - name: name
value: string
- name: priority
value: integer
- name: enabledState
value: string
- name: ruleType
value: string
- name: rateLimitDurationInMinutes
value: integer
- name: rateLimitThreshold
value: integer
- name: groupBy
value:
- - name: variableName
value: string
- name: matchConditions
value:
- - name: matchVariable
value: string
- name: selector
value: string
- name: operator
value: string
- name: negateCondition
value: boolean
- name: matchValue
value:
- string
- name: transforms
value:
- []
- name: action
value: []
- name: managedRules
value:
- name: managedRuleSets
value:
- - name: ruleSetType
value: string
- name: ruleSetVersion
value: string
- name: ruleSetAction
value: []
- name: exclusions
value:
- - name: matchVariable
value: string
- name: selectorMatchOperator
value: string
- name: selector
value: string
- name: ruleGroupOverrides
value:
- - name: ruleGroupName
value: string
- name: exclusions
value:
- - name: matchVariable
value: string
- name: selectorMatchOperator
value: string
- name: selector
value: string
- name: rules
value:
- - name: ruleId
value: string
- name: enabledState
value: []
- name: exclusions
value:
- - name: matchVariable
value: string
- name: selectorMatchOperator
value: string
- name: selector
value: string
- name: frontendEndpointLinks
value:
- - name: id
value: string
- name: routingRuleLinks
value:
- - name: id
value: string
- name: securityPolicyLinks
value:
- - name: id
value: string
- name: provisioningState
value: string
- name: resourceState
value: string
- name: etag
value: string
- name: sku
value:
- name: name
value: string
- name: id
value: string
- name: name
value: string
- name: type
value: string
- name: location
value: string
- name: tags
value: object
UPDATE
example
Updates a policies
resource.
/*+ update */
UPDATE azure.front_door.policies
SET
tags = '{{ tags }}'
WHERE
policyName = '{{ policyName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
DELETE
example
Deletes the specified policies
resource.
/*+ delete */
DELETE FROM azure.front_door.policies
WHERE policyName = '{{ policyName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';