-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GuestPatching: Adding AutomaticByPlatformSettings (in VMSS and VM mod…
…el) and useRollingUpgradePolicy (in VMSS model) properties (#18581) * GuestPatching: Adding AutomaticByPlatofrmSettings within Linux and Windows Patch settings for VM and VMSS model * Updating examples related to AutomaticByPlatformSettings property in PatchSettings for VM and VMSS model * Adding useRollingUpgradePolicy property to automaticOSUpgradePolicy for VMSS and other minor changes for AutomaticByPlatfrom settings * Addressing PR feedback * Addressing PR feedback #2 * Renaming reboot reference for windows and linux automaticbyplatform patch settings - reboot settings * Resolving errors reported on the PR by Avocado and LintDiff
- Loading branch information
1 parent
93665b8
commit 527cdde
Showing
7 changed files
with
425 additions
and
6 deletions.
There are no files selected for viewing
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
175 changes: 175 additions & 0 deletions
175
.../virtualMachineExamples/VirtualMachine_Create_LinuxVmWithAutomaticByPlatformSettings.json
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,175 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "{subscription-id}", | ||
"resourceGroupName": "myResourceGroup", | ||
"vmName": "myVM", | ||
"api-version": "2022-03-01", | ||
"parameters": { | ||
"location": "westus", | ||
"properties": { | ||
"hardwareProfile": { | ||
"vmSize": "Standard_D2s_v3" | ||
}, | ||
"storageProfile": { | ||
"imageReference": { | ||
"sku": "16.04-LTS", | ||
"publisher": "Canonical", | ||
"version": "latest", | ||
"offer": "UbuntuServer" | ||
}, | ||
"osDisk": { | ||
"caching": "ReadWrite", | ||
"managedDisk": { | ||
"storageAccountType": "Premium_LRS" | ||
}, | ||
"name": "myVMosdisk", | ||
"createOption": "FromImage" | ||
} | ||
}, | ||
"osProfile": { | ||
"adminUsername": "{your-username}", | ||
"computerName": "myVM", | ||
"adminPassword": "{your-password}", | ||
"linuxConfiguration": { | ||
"provisionVMAgent": true, | ||
"patchSettings": { | ||
"patchMode": "AutomaticByPlatform", | ||
"assessmentMode": "AutomaticByPlatform", | ||
"automaticByPlatformSettings": { | ||
"rebootSetting": "Never" | ||
} | ||
} | ||
} | ||
}, | ||
"networkProfile": { | ||
"networkInterfaces": [ | ||
{ | ||
"id": "/subscriptions/{subscription-id}/resourceGroups/myResourceGroup/providers/Microsoft.Network/networkInterfaces/{existing-nic-name}", | ||
"properties": { | ||
"primary": true | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "/subscriptions/{subscription-id}/resourceGroups/myResourceGroup/providers/Microsoft.Compute/virtualMachines/myVM", | ||
"type": "Microsoft.Compute/virtualMachines", | ||
"properties": { | ||
"osProfile": { | ||
"adminUsername": "{your-username}", | ||
"secrets": [], | ||
"computerName": "myVM", | ||
"linuxConfiguration": { | ||
"provisionVMAgent": true, | ||
"patchSettings": { | ||
"patchMode": "AutomaticByPlatform", | ||
"assessmentMode": "AutomaticByPlatform", | ||
"automaticByPlatformSettings": { | ||
"rebootSetting": "Never" | ||
} | ||
} | ||
} | ||
}, | ||
"networkProfile": { | ||
"networkInterfaces": [ | ||
{ | ||
"id": "/subscriptions/{subscription-id}/resourceGroups/myResourceGroup/providers/Microsoft.Network/networkInterfaces/nsgExistingNic", | ||
"properties": { | ||
"primary": true | ||
} | ||
} | ||
] | ||
}, | ||
"storageProfile": { | ||
"imageReference": { | ||
"sku": "16.04-LTS", | ||
"publisher": "Canonical", | ||
"version": "latest", | ||
"offer": "UbuntuServer" | ||
}, | ||
"osDisk": { | ||
"osType": "Linux", | ||
"caching": "ReadWrite", | ||
"createOption": "FromImage", | ||
"name": "myVMosdisk", | ||
"managedDisk": { | ||
"storageAccountType": "Premium_LRS" | ||
} | ||
}, | ||
"dataDisks": [] | ||
}, | ||
"vmId": "a149cd25-409f-41af-8088-275f5486bc93", | ||
"hardwareProfile": { | ||
"vmSize": "Standard_D2s_v3" | ||
}, | ||
"provisioningState": "Creating" | ||
}, | ||
"name": "myVM", | ||
"location": "westus" | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"id": "/subscriptions/{subscription-id}/resourceGroups/myResourceGroup/providers/Microsoft.Compute/virtualMachines/myVM", | ||
"type": "Microsoft.Compute/virtualMachines", | ||
"properties": { | ||
"osProfile": { | ||
"adminUsername": "{your-username}", | ||
"secrets": [], | ||
"computerName": "myVM", | ||
"linuxConfiguration": { | ||
"provisionVMAgent": true, | ||
"patchSettings": { | ||
"patchMode": "AutomaticByPlatform", | ||
"assessmentMode": "AutomaticByPlatform", | ||
"automaticByPlatformSettings": { | ||
"rebootSetting": "Never" | ||
} | ||
} | ||
} | ||
}, | ||
"networkProfile": { | ||
"networkInterfaces": [ | ||
{ | ||
"id": "/subscriptions/{subscription-id}/resourceGroups/myResourceGroup/providers/Microsoft.Network/networkInterfaces/nsgExistingNic", | ||
"properties": { | ||
"primary": true | ||
} | ||
} | ||
] | ||
}, | ||
"storageProfile": { | ||
"imageReference": { | ||
"sku": "16.04-LTS", | ||
"publisher": "Canonical", | ||
"version": "latest", | ||
"offer": "UbuntuServer" | ||
}, | ||
"osDisk": { | ||
"osType": "Linux", | ||
"caching": "ReadWrite", | ||
"createOption": "FromImage", | ||
"name": "myVMosdisk", | ||
"managedDisk": { | ||
"storageAccountType": "Premium_LRS" | ||
} | ||
}, | ||
"dataDisks": [] | ||
}, | ||
"vmId": "a149cd25-409f-41af-8088-275f5486bc93", | ||
"hardwareProfile": { | ||
"vmSize": "Standard_D2s_v3" | ||
}, | ||
"provisioningState": "Creating" | ||
}, | ||
"name": "myVM", | ||
"location": "westus" | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.