Explanation Sysprep removes all your personal account and security information, and then prepares the machine to be used as an image. The Add-AzureRmVhd cmdlet uploads on-premises virtual hard disks, in .vhd file format, to a blob storage account as fixed virtual hard disks. References: https://docs.microsoft.com/en-us/powershell/module/azurerm.compute/add-azurermvhd?view=azurermps-6.13.0 https://docs.microsoft.com/en-us/azure/virtual-machines/windows/capture-image-resource