The identity type. This is the only required field when adding a system or user assigned identity to a resource.
'None' 'SystemAssigned' 'UserAssigned'
userAssignedIdentities
The user identity associated with the policy. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
Use when creating a resource at a scope that is different than the deployment scope.
Set this property to the symbolic name of a resource to apply the extension resource.
NonComplianceMessage
Name
Description
Value
message
A message that describes why a resource is non-compliant with the policy. This is shown in 'deny' error messages and on resource's non-compliant compliance results.
string (required)
policyDefinitionReferenceId
The policy definition reference ID within a policy set definition the message is intended for. This is only applicable if the policy assignment assigns a policy set definition. If this is not provided the message applies to all policies assigned by this policy assignment.
string
ParameterValues
Name
Description
Value
ParameterValuesValue
Name
Description
Value
value
The value of the parameter.
any
PolicyAssignmentProperties
Name
Description
Value
description
This message will be part of response in case of policy violation.
string
displayName
The display name of the policy assignment.
string
enforcementMode
The policy assignment enforcement mode. Possible values are Default and DoNotEnforce.
'Default' 'DoNotEnforce'
metadata
The policy assignment metadata. Metadata is an open ended object and is typically a collection of key value pairs.
any
nonComplianceMessages
The messages that describe why a resource is non-compliant with the policy.
This template deploys an Azure Virtual Network Manager and sample virtual networks into the named resource group. It supports multiple connectivity topologies and network group membership types.
This template is a management group level template that will create a policy definition and assign that policy to the target management group. Currently, this template cannot be deployed via the Azure Portal.
ARM template resource definition
The policyAssignments resource type can be deployed with operations that target:
For a list of changed properties in each API version, see change log.
Resource format
To create a Microsoft.Authorization/policyAssignments resource, add the following JSON to your template.
The identity type. This is the only required field when adding a system or user assigned identity to a resource.
'None' 'SystemAssigned' 'UserAssigned'
userAssignedIdentities
The user identity associated with the policy. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
A message that describes why a resource is non-compliant with the policy. This is shown in 'deny' error messages and on resource's non-compliant compliance results.
string (required)
policyDefinitionReferenceId
The policy definition reference ID within a policy set definition the message is intended for. This is only applicable if the policy assignment assigns a policy set definition. If this is not provided the message applies to all policies assigned by this policy assignment.
string
ParameterValues
Name
Description
Value
ParameterValuesValue
Name
Description
Value
value
The value of the parameter.
any
PolicyAssignmentProperties
Name
Description
Value
description
This message will be part of response in case of policy violation.
string
displayName
The display name of the policy assignment.
string
enforcementMode
The policy assignment enforcement mode. Possible values are Default and DoNotEnforce.
'Default' 'DoNotEnforce'
metadata
The policy assignment metadata. Metadata is an open ended object and is typically a collection of key value pairs.
any
nonComplianceMessages
The messages that describe why a resource is non-compliant with the policy.
This template deploys an Azure Virtual Network Manager and sample virtual networks into the named resource group. It supports multiple connectivity topologies and network group membership types.
This template is a management group level template that will create a policy definition and assign that policy to the target management group. Currently, this template cannot be deployed via the Azure Portal.
Terraform (AzAPI provider) resource definition
The policyAssignments resource type can be deployed with operations that target:
For a list of changed properties in each API version, see change log.
Resource format
To create a Microsoft.Authorization/policyAssignments resource, add the following Terraform to your template.
The identity type. This is the only required field when adding a system or user assigned identity to a resource.
'None' 'SystemAssigned' 'UserAssigned'
userAssignedIdentities
The user identity associated with the policy. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
A message that describes why a resource is non-compliant with the policy. This is shown in 'deny' error messages and on resource's non-compliant compliance results.
string (required)
policyDefinitionReferenceId
The policy definition reference ID within a policy set definition the message is intended for. This is only applicable if the policy assignment assigns a policy set definition. If this is not provided the message applies to all policies assigned by this policy assignment.
string
ParameterValues
Name
Description
Value
ParameterValuesValue
Name
Description
Value
value
The value of the parameter.
any
PolicyAssignmentProperties
Name
Description
Value
description
This message will be part of response in case of policy violation.
string
displayName
The display name of the policy assignment.
string
enforcementMode
The policy assignment enforcement mode. Possible values are Default and DoNotEnforce.
'Default' 'DoNotEnforce'
metadata
The policy assignment metadata. Metadata is an open ended object and is typically a collection of key value pairs.
any
nonComplianceMessages
The messages that describe why a resource is non-compliant with the policy.