An organization, Zenith Retail, is designing an Azure governance strategy. The resource hierarchy consists of a root management group named Zenith-Root, with a child management group named Prod-MG containing all production subscriptions.
You must design an Azure Policy solution assigned at the Prod-MG level to meet the following requirements:
1. All virtual machines must have the Azure Monitor Agent installed and configured. Non-compliant virtual machines must be automatically configured upon deployment.
2. All new resource groups must automatically have a cost-center tag (CostCenter: 4002) applied if they are created without one, without blocking deployment.
3. No public IP addresses may be deployed within the subscriptions under Prod-MG, except for a specific shared services resource group named Shared-Gateway-RG where public IPs are permitted for firewalls.
Which two of the following design actions should the cloud architect implement to meet these requirements while minimizing administrative overhead?
- Create and assign a policy initiative at the Prod-MG scope that contains a policy definition using the DeployIfNotExists effect to install the Azure Monitor Agent and a policy definition using the Modify effect to append the cost-center tag.Cevap
- Assign a policy definition using the Deny effect for public IP resources at the Prod-MG scope, and configure the resource ID of Shared-Gateway-RG within the notScopes (exclusions) property of the policy assignment.Cevap
- CAssign a policy definition using the Deny effect for virtual machines lacking the Azure Monitor Agent at the Prod-MG scope, and configure an Azure Event Grid subscription to trigger an Azure Function that installs the agent.
- DAssign a policy definition using the Audit effect for missing resource group tags at the Prod-MG scope, and use a scheduled Azure Automation runbook to apply the tags to non-compliant resource groups.