sns You can add tags to the virtual machines and filter them based on your requirement. The -FilterTag
parameter in the New-AzConfigurationAssignment
cmdlet is used to filter the virtual machines that will be included in the maintenance configuration. The tag key-value pairs that you specify in the filter will be used to match against the tags that are assigned to the virtual machines.
For example, if you have assigned the tag "Environment" with the value "Production" to your virtual machines, you can use the following filter to include only those virtual machines in the maintenance configuration:
-FilterTag '{"Environment" : ["Production"]}'