этот шаблон руки должен работать:
{
"apiVersion": "2017-05-15-preview",
"type": "Microsoft.Automation/automationAccounts/softwareUpdateConfigurations",
"name": "automationName/softwareUpdateName",
"location": "[resourceGroup().location]",
"properties": {
"updateConfiguration": {
"operatingSystem": "Windows",
"duration": "PT2H0M",
"windows": {
"excludedKbNumbers": [
"168934",
"168973"
],
"includedUpdateClassifications": "Critical",
"rebootSetting": "IfRequired"
},
"azureVirtualMachines": [
"/subscriptions/5ae68d89-69a4-454f-b5ce-e443cc4e0067/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-01",
"/subscriptions/5ae68d89-69a4-454f-b5ce-e443cc4e0067/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-02",
"/subscriptions/5ae68d89-69a4-454f-b5ce-e443cc4e0067/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-03"
],
"nonAzureComputerNames": [
"box1.contoso.com",
"box2.contoso.com"
]
},
"scheduleInfo": {
"frequency": "Hour",
"startTime": "2017-10-19T12:22:57+00:00",
"timeZone": "America/Los_Angeles",
"interval": 1,
"expiryTime": "2018-11-09T11:22:57+00:00",
"advancedSchedule": {
"weekDays": [
"Monday",
"Thursday"
]
}
}
}
}
Вы можете использовать остальные API, чтобы узнать, как построить properties
так, как вам нужно.
вы можете использоватьтот же properties
json с invoke-webrequest в качестве полезной нагрузки, например, или curl.