Kai Walter
Kai Walter

Reputation: 4041

How can I add Managed Identity to a DevTest Labs VM?

I want to develop and test MSI on my development Windows VM which I created with DevTest Labs.

Going into the VM directly on Identity (Preview) I can change the setting but the Save keeps being disabled.

Upvotes: 1

Views: 204

Answers (1)

Kai Walter
Kai Walter

Reputation: 4041

I managed to achieve this with Azure CLI:

  1. log in to Azure CLI, select Account
  2. list VMs with az vm list
  3. choose the VM to assign MSI to
  4. run az vm identity assign --name {vm-name} -g {vms resource groupname}

checking in the portal, VM / Identity tab, the Identity has Status=On

Upvotes: 1

Related Questions