Custom Role definition not showing in Azure Portal

Brass Contributor

Ive just created a custom role via powershell and confirmed that it worked in PS and can get the ID with with Get-AzRoleDefinition | ? {$_.IsCustom -eq $true} | FT Name, IsCustom   

but it simply does not show up in the Azure Portal  under Roles and Administrators. Ive tried refreshing , seraching with a filter for custom role type, searching by name but after an hour still not there

I have Global Admin rights and I cannot think of why this would be unless there is currently some kind of synching issue going in the Azure Infrastructure.

Anyone have any ideas as to why this might be ? Ive tried creating it twice also in case it was a glitch with the first one.

3 Replies

@PhilRiceUoS I think you have used the New-AzRoleAssignment cmdlet. This is creating a custom role for Azure resources. I think you need to use New-AzureADMSRoleDefinition cmdlet to create a Azure AD role and that shows up in the "Roles and administrators" blade. Not 100% sure, but you can check it out!

Thanks I will give that a try tomorrow and update with my results.

Hi @PhilRiceUoS,

I know this might be a late reply, and I'm not this answer works on your situation, but to inform other readers, in order to create custom role, Azure AD Premium P1 or P2 is a requirement. I hope it helps others as it came in handy for myself :)