Difference between revisions of "Az vm create"
Jump to navigation
Jump to search
(Created page with "# az cli create vm set -a RG=foo VM=foo NIC=$VM-nic1 VNET=foo SUBNET=foo ``` az network nic create --resource-group $RG--name $NIC --vnet-name $VNET--subnet $SUBNET az vm c...") |
|||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
# az cli create vm | # az cli create vm | ||
− | + | ``` | |
set -a | set -a | ||
RG=foo | RG=foo | ||
Line 7: | Line 7: | ||
VNET=foo | VNET=foo | ||
SUBNET=foo | SUBNET=foo | ||
− | + | ``` | |
``` | ``` | ||
az network nic create --resource-group $RG--name $NIC --vnet-name $VNET--subnet $SUBNET | az network nic create --resource-group $RG--name $NIC --vnet-name $VNET--subnet $SUBNET | ||
− | az vm create --resource-group $RG --name $VM --size Standard_D4s_v5 --image Ubuntu2204 --nics $NIC --ssh-key-values @~/.ssh/myid.pub | + | az vm create --resource-group $RG --name $VM --size Standard_D4s_v5 --image Ubuntu2204 --nics $NIC --admin-username myuser --ssh-key-values @~/.ssh/myid.pub |
``` | ``` |
Latest revision as of 04:45, 22 May 2024
az cli create vm
set -a RG=foo VM=foo NIC=$VM-nic1 VNET=foo SUBNET=foo
az network nic create --resource-group $RG--name $NIC --vnet-name $VNET--subnet $SUBNET az vm create --resource-group $RG --name $VM --size Standard_D4s_v5 --image Ubuntu2204 --nics $NIC --admin-username myuser --ssh-key-values @~/.ssh/myid.pub