okay azure | Create Virtual Machine in Azure CLI Interactive Mode | Microsoft azure |

Опубликовано: 13 Октябрь 2024
на канале: Java Interview Prep
265
2

#okayazure#createvm #azureCLI#interactivemode#microsoftazure#CLI#virtualmachine

Create a resource group
az group create -l eastus2 -n testRG01

Create a Virtual machine
az vm create --name testVM -g testRG01 --image Win2019Datacenter --size Standard_D4_v3 --admin-username azureuser --admin-password TestPassword01 --nsg-rule RDP

open port 3389
az vm open-port --port 3389 -g testRG01 -n testVM

open port 80 -
vm open-port --port 80 -g testRG01 -n testVM --priority 100

List VM
az vm list -o table

RDP virtual machine
1) win+R : mstsc
Enter public ip address of your VM
2)then enter username and password to connect

delete a resource group
az group delete -n testRG01