Yes, go to the Role in Azure and add there
Assigning ad role - global reader role to service principal
I am trying to assign ad role- global reader to service principal in terraform. I says role not found. Want to know whether I can assign ad role to service principal. I am getting this error on trying to assign global reader role to service principal-
Error: loading Role Definition List: could not find role 'Global Reader'
│
│ with module.infrastructure_cloud-scanner-app.azurerm_role_assignment.main["/subscriptions/aeca76e8-1861-4aed-b28a-b8c48923f89b"],
│ on ../../modules/infrastructure/cloud-scanner-app/main.tf line 49, in resource "azurerm_role_assignment" "main":
│ 49: resource "azurerm_role_assignment" "main" {
Microsoft Security | Microsoft Entra | Microsoft Entra ID
2 answers
Sort by: Most helpful
-
Andy David - MVP 157.8K Reputation points
2022-08-04T14:20:14.073+00:00 -
James Hamil 27,221 Reputation points Microsoft Employee Moderator
2022-11-09T20:39:36.117+00:00 Hi @Nitin Naidu , please try using
role_definition_id
in place ofrole_definition_name
as suggested in the GitHub link above. Please let me know if this works or not.Best,
James