Skip to content

Commit 0ee1275

Browse files
Clarify language describing existenceScope property
1 parent cf004c7 commit 0ee1275

File tree

1 file changed

+18
-19
lines changed

1 file changed

+18
-19
lines changed

articles/governance/policy/concepts/effects.md

Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Understand how effects work
33
description: Azure Policy definitions have various effects that determine how compliance is managed and reported.
44
author: timwarner-msft
5-
ms.date: 10/20/2022
5+
ms.date: 02/22/2023
66
ms.topic: conceptual
77
ms.author: timwarner
88
---
@@ -51,10 +51,10 @@ manages the evaluation and outcome and reports the results back to Azure Policy.
5151
Resource Manager mode.
5252
- **Deny** is then evaluated. By evaluating deny before audit, double logging of an undesired
5353
resource is prevented.
54-
- **Audit** is evaluated.
55-
- **Manual** is evaluated.
56-
- **AuditIfNotExists** is evaluated.
57-
- **denyAction** is evaluated last.
54+
- **Audit** is evaluated.
55+
- **Manual** is evaluated.
56+
- **AuditIfNotExists** is evaluated.
57+
- **denyAction** is evaluated last.
5858

5959
After the Resource Provider returns a success code on a Resource Manager mode request,
6060
**AuditIfNotExists** and **DeployIfNotExists** evaluate to determine whether additional compliance
@@ -460,21 +460,21 @@ location of the Constraint template to use in Kubernetes to limit the allowed co
460460
### DenyAction evaluation
461461

462462
When a request call with an applicable action name and targeted scope is submitted, `denyAction` prevents the request from succeeding. The request is returned as a `403 (Forbidden)`. In the portal, the Forbidden can be viewed as a status on the deployment that was prevented by the policy
463-
assignment.
463+
assignment.
464464

465-
`Microsoft.Authorization/policyAssignments`, `Microsoft.Authorization/denyAssignments`, `Microsoft.Blueprint/blueprintAssignments`, `Microsoft.Resources/deploymentStacks`, and `Microsoft.Authorization/locks` are all exempt from DenyAction enforcement to prevent lockout scenarios.
465+
`Microsoft.Authorization/policyAssignments`, `Microsoft.Authorization/denyAssignments`, `Microsoft.Blueprint/blueprintAssignments`, `Microsoft.Resources/deploymentStacks`, and `Microsoft.Authorization/locks` are all exempt from DenyAction enforcement to prevent lockout scenarios.
466466

467467
> [!NOTE]
468468
> Under preview, assignments with `denyAction` effect will show a `Not Started` compliance state.
469469
470470
#### Subscription deletion
471-
Policy won't block removal of resources that happens during a subscription deletion.
471+
Policy won't block removal of resources that happens during a subscription deletion.
472472

473-
#### Resource group deletion
474-
Policy will evaluate resources that support location and tags against `DenyAction` policies during a resource group deletion. Only policies that have the `cascadeBehaviors` set to `deny` in the policy rule will block a resource group deletion. Policy won't block removal of resources that don't support location and tags nor any policy with `mode:all`.
473+
#### Resource group deletion
474+
Policy will evaluate resources that support location and tags against `DenyAction` policies during a resource group deletion. Only policies that have the `cascadeBehaviors` set to `deny` in the policy rule will block a resource group deletion. Policy won't block removal of resources that don't support location and tags nor any policy with `mode:all`.
475475

476476
#### Cascade deletion
477-
Cascade deletion occurs when deleting of a parent resource is implicitly deletes all its child resources. Policy won't block removal of child resources when a delete action targets the parent resources. For example, `Microsoft.Insights/diagnosticSettings` is a child resource of `Microsoft.Storage/storageaccounts`. If a `denyAction` policy targets `Microsoft.Insights/diagnosticSettings`, a delete call to the diagnostic setting (child) will fail, but a delete to the storage account (parent) will implicitly delete the diagnostic setting (child).
477+
Cascade deletion occurs when deleting of a parent resource is implicitly deletes all its child resources. Policy won't block removal of child resources when a delete action targets the parent resources. For example, `Microsoft.Insights/diagnosticSettings` is a child resource of `Microsoft.Storage/storageaccounts`. If a `denyAction` policy targets `Microsoft.Insights/diagnosticSettings`, a delete call to the diagnostic setting (child) will fail, but a delete to the storage account (parent) will implicitly delete the diagnostic setting (child).
478478

479479
[!INCLUDE [policy-denyAction](../../../../includes/azure-policy-deny-action.md)]
480480

@@ -483,16 +483,16 @@ Cascade deletion occurs when deleting of a parent resource is implicitly deletes
483483
The **details** property of the DenyAction effect has all the subproperties that define the action and behaviors.
484484

485485
- **actionNames** (required)
486-
- An _array_ that specifies what actions to prevent from being executed.
487-
- Supported action names are: `delete`.
486+
- An _array_ that specifies what actions to prevent from being executed.
487+
- Supported action names are: `delete`.
488488
- **cascadeBehaviors** (optional)
489-
- An _object_ that defines what behavior will be followed when the resource is being implicitly deleted by the removal of a resource group.
489+
- An _object_ that defines what behavior will be followed when the resource is being implicitly deleted by the removal of a resource group.
490490
- Only supported in policy definitions with [mode](./definition-structure.md#resource-manager-modes) set to `indexed`.
491-
- Allowed values are `allow` or `deny`.
492-
- Default value is `deny`.
491+
- Allowed values are `allow` or `deny`.
492+
- Default value is `deny`.
493493

494494
### DenyAction example
495-
Example: Deny any delete calls targeting database accounts that have a tag environment that equals prod. Since cascade behavior is set to deny, block any DELETE call that targets a resource group with an applicable database account.
495+
Example: Deny any delete calls targeting database accounts that have a tag environment that equals prod. Since cascade behavior is set to deny, block any DELETE call that targets a resource group with an applicable database account.
496496

497497
```json
498498
{
@@ -565,8 +565,7 @@ related resources to match and the template deployment to execute.
565565
- Allowed values are _Subscription_ and _ResourceGroup_.
566566
- Sets the scope of where to fetch the related resource to match from.
567567
- Doesn't apply if **type** is a resource that would be underneath the **if** condition resource.
568-
- For _ResourceGroup_, would limit to the **if** condition resource's resource group or the
569-
resource group specified in **ResourceGroupName**.
568+
- For _ResourceGroup_, would limit to the resource group in **ResourceGroupName** if specified. If **ResourceGroupName** isn't specified, would limit to the **if** condition resource's resource group, which is the default behavior.
570569
- For _Subscription_, queries the entire subscription for the related resource. Assignment scope should be set at subscription or higher for proper evaluation.
571570
- Default is _ResourceGroup_.
572571
- **EvaluationDelay** (optional)

0 commit comments

Comments
 (0)