Created
November 28, 2022 16:52
-
-
Save andrewmatveychuk/7e4e102b84b30f416cdb886d4fa6cac2 to your computer and use it in GitHub Desktop.
Sample Azure Policy rule to evaluate Windows Client VMs for Azure Hybrid Benefit usage
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"if": { | |
"allOf": [ | |
{ | |
"field": "type", | |
"equals": "Microsoft.Compute/virtualMachines" | |
}, | |
{ | |
"field": "Microsoft.Compute/imagePublisher", | |
"equals": "MicrosoftWindowsDesktop" | |
}, | |
{ | |
"field": "Microsoft.Compute/imageOffer", | |
"in": "[[parameters('imageOffers')]" | |
}, | |
{ | |
"field": "Microsoft.Compute/virtualMachines/licenseType", | |
"notEquals": "Windows_Client" | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment