CmdID

CmdID / az / az policy / az policy definition / az policy definition version

az policy definition version create

Create a policy definition version. Azure CLI reference

Create a policy definition version in the given subscription or management group with the given name and other properties.

1 example 7 options Its page in the Azure CLI reference

Opens CmdID with your command. It is read in your browser and sent nowhere.

Examples

from the Azure CLI, each command read by CmdID

Create a policy definition with older version

az policy definition version create --name readOnlyStorage --rules "{ 'if': { 'field': 'type', 'equals': 'Microsoft.Storage/storageAccounts/write' }, 'then': { 'effect': 'deny' } }" --version 1.1.0Identify
--nameThe name of the policy definition.
--rulesThe policy rule.

Options

7 in the Azure CLI reference
--descriptionThe policy definition description.
--display-nameThe display name of the policy definition.
--external-evaluation-enforcement-settings, --external-settingsThe details of the source of external evaluation results required by the policy during enforcement evaluation.
--management-groupThe management group.
--metadata, --version, --params, --mode, -m, -p
--name, -nThe name of the policy definition.
--rules, --ruleThe policy rule.