Search code examples
azure-logic-appsazure-log-analyticsazure-managed-identityazure-service-principalazure-managed-app

Configure Logic App with Managed Identity


I am new to the Azure services and seek help with the Managed Identities. My task is to create a managed connection between my Logic App and my Log Analytics Workspace. I have created a system assigned identity and have the respective object ID. When I use the Azure Logs Monitor action in my logic app, it asks if I should connect by signing in or service principal. Image for Azure Log Analytics Action fields when service principal option is selected.

What should be the next step, should I add the Object ID of my logic app in the log analytics workspace, then what about the fields in the above image link.


Solution

  • Service Principal doesn't have any roles in the scenario above. The image asks for an app's client ID, Tenant ID and secret. All we need to do is create an app in the app registration, create a secret in it and get these three parameters from there. Add this app as a contributor or desired role as per need in the workspace (in my case which is Log Analytics workspace), add the three parameters into the Logic App action as seen in above image and we are good to go. The Logic app would run on the managed connection now.