Forum Discussion
danielcregg
Feb 18, 2022Copper Contributor
Azure CLI create VM and assign it a password AND a ssh key for login?
How do I create a VM using Azure CLI and assign it a password AND a ssh key for login? Here is the command I want to use but it just creates the ssh key and ignores creating the password. az vm...
- Feb 21, 2022Based on the info in the docs, it looks like you need to set the auth type to all to allow both SSH & password:
--authentication-type
Type of authentication to use with the VM. Defaults to password for Windows and SSH public key for Linux. "all" enables both ssh and password authentication.
accepted values: all, password, ssh
ezeelogin
Apr 29, 2022Copper Contributor
good stuff thanks for contribution