Skill 3.2.2
Describe the purpose of Azure Policy
Key Concepts
A policy definition describes a condition and an effect, such as allow only these regions or require a tag. Microsoft provides hundreds of built-in definitions, and custom definitions can be written in JSON. A definition takes effect when it is assigned to a scope: a management group, subscription or resource group, from which it is inherited by everything below. Related definitions can be grouped into an initiative, such as a regulatory standard, and assigned together.
Policies are evaluated when resources are created or changed and periodically afterwards. Effects include Deny (block a non-compliant request), Audit (allow it but flag it as non-compliant), Append or Modify (change the request, for example to add a tag) and DeployIfNotExists (deploy a related resource or setting). The compliance dashboard shows which resources do not comply, and remediation can fix many existing resources. Azure Policy integrates with Azure DevOps and can be extended to on-premises and other-cloud resources through Azure Arc.