locked
Pass Managed Identity Object ID to KeyVault RRS feed

  • Question

  • So, I am trying to spin up a Managed Identity and a KeyVault using Blueprints. I have an individually working template for each. My endgoal is to spin up both resources along with a few more together in the same blueprint. The issue I'm having is that I need to pass my Managed Identity's object ID to the KeyVault template during deployment. I have the blueprint setup to deploy the managed identity resource group, then the managed identity, followed by the keyvault group and keyvault. The deployment is working till the KV resource group and then failing during deployment of keyvault. Does anyone have any insight on how to do this? Below are 2 pics that show the layout of the blueprint and also the section of the keyvault template where the object Id is needed
    Friday, April 10, 2020 8:49 PM

All replies

  • Have you tried passing like below  - 

    [reference(concat('Microsoft.ManagedIdentity/userAssignedIdentities/',parameters('managedIdentityRG'))).principalId]
    Also, you may try to pass the manged identity version. Please refer to the blog for details.

    Monday, April 13, 2020 8:52 PM