Azure CLI 2 · Resource groups and VMs

Create a Linux VM

Create a VM with SSH keys generated for you.

az vm create --resource-group my-rg --name my-vm --image Ubuntu2204 --admin-username azureuser --generate-ssh-keys

Official Azure CLI 2 documentation

More resource groups and vms commands

All resource groups and vms commands · Azure CLI 2 cheatsheet

Was this page helpful?