Recommended SPN permissions for this terraform-azurerm-policy-exemptions module #11
-
Hello again, and thanks for adding the minimum Terraform CLI version required from my other ticket #3
These "Microsoft.Resources/deployments" permissions look like are due to the use of "azurerm_resource_group_template_deployment" module. The challenge we have now is by providing the SPN to create policy exemptions with these permissions, the SPN also has higher privileges to create/modify other resources. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Hi @tpidor There's currently no Azure RBAC built-in role which only provides access to manage only ARM template deployments and policy exemptions If constraining the SPN to the least permissions possible to use this module is a requirement I recommend creating a custom role with at least these 2x actions only, then assign your SPN to the new custom role: Microsoft.Resources/deployments/* -- Create and manage a deployment https://docs.microsoft.com/en-us/azure/role-based-access-control/custom-roles Hope this helps |
Beta Was this translation helpful? Give feedback.
Hi @tpidor
There's currently no Azure RBAC built-in role which only provides access to manage only ARM template deployments and policy exemptions
If constraining the SPN to the least permissions possible to use this module is a requirement I recommend creating a custom role with at least these 2x actions only, then assign your SPN to the new custom role:
Microsoft.Resources/deployments/* -- Create and manage a deployment
Microsoft.Authorization/policyexemptions/* -- Create and manage policy exemptions
https://docs.microsoft.com/en-us/azure/role-based-access-control/custom-roles
Hope this helps