-1

I´m trying to create such Azure Bicep/ARM script that will deploy new Azure VM with new unmanaged disk, optionaly with custom size (for example 60 Gb).

I have consider many option including (and most promising looking)custom image, but from my understanding I still need existing vhd in storage blob prior deploynment and I can´t find any other way how to create vhd than that I create VM in portal with unmanaged disk and than detaching it, unfortunatelly that is really no option for me because I´m trying to automate whole process...

Thank you in advance for any advice, even simple it cannot be done, will help me, thanks

1 Answers1

0

Per my understanding, you want to create VMs by ARM template via your custom image, You can refer to docs below to capture VM images:

Capture windows VM image

Capture Linux VM image

If you want to use managed images to create VMs by ARM template, you can just specify your managed images resource ID in imageReference. You can find detailed steps in this blog.

You also could create VMs from the Azure portal or by PowerShell

Stanley Gong
  • 11,522
  • 1
  • 8
  • 16