mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-03-13 18:59:26 +00:00
Update cheatsheets
This commit is contained in:
38
az-vm
Normal file
38
az-vm
Normal file
@@ -0,0 +1,38 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, common]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# az vm
|
||||
|
||||
> Manage virtual machines in Azure.
|
||||
> Part of `azure-cli` (also known as `az`).
|
||||
> More information: <https://learn.microsoft.com/cli/azure/vm>.
|
||||
|
||||
- List details of available Virtual Machines:
|
||||
|
||||
`az vm list`
|
||||
|
||||
- Create a virtual machine using the default Ubuntu image and generate ssh keys:
|
||||
|
||||
`az vm create --resource-group {{rg}} --name {{vm_name}} --image {{UbuntuLTS}} --admin-user {{azureuser}} --generate-ssh-keys`
|
||||
|
||||
- Stop a Virtual Machine:
|
||||
|
||||
`az vm stop --resource-group {{rg}} --name {{vm_name}}`
|
||||
|
||||
- Deallocate a Virtual Machine:
|
||||
|
||||
`az vm deallocate --resource-group {{rg}} --name {{vm_name}}`
|
||||
|
||||
- Start a Virtual Machine:
|
||||
|
||||
`az vm start --resource-group {{rg}} --name {{vm_name}}`
|
||||
|
||||
- Restart a Virtual Machine:
|
||||
|
||||
`az vm restart --resource-group {{rg}} --name {{vm_name}}`
|
||||
|
||||
- List VM images available in the Azure Marketplace:
|
||||
|
||||
`az vm image list`
|
||||
Reference in New Issue
Block a user