Skip to content

az vm create doesn't work if the user specifies an admin password + ssh key; gives an unhelpful error message #6230

Description

@colemickens

$ az vm create --name=colemick-nixosdev1 --resource-group=colemick-nixosdev1 --admin-username=cole --admin-password=redacted '--ssh-key-value=...' --size=Standard_D16s_v3 --image=/subscriptions/aff271ee-e9be-4441-b9bb-42f5af4cbaeb/resourceGroups/aznixos/providers/Microsoft.Compute/images/nixos-image-16.09.1694.019dcc3-x86_64-linux-vhd

az vm create: error: incorrect usage for authentication-type 'password': [--admin-username USERNAME] --admin-password PASSWORD

and then it works if I removed the SSH key.

  1. The error message is unhelpful.
  2. This should be allowed...

Metadata

Metadata

Assignees

Labels

Computeaz vm/vmss/image/disk/snapshot

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions