← cd ~/roles
// roles/azure · monitor
Application Insights Component ContributorAzure built-in role
Can manage Application Insights components
| Role ID | ae349356-3a1b-4a5e-921d-050484c6347e |
|---|---|
| Category | Monitor |
| Actions | 13 |
| Data actions | 0 |
What it can do
| Permission | What it allows |
|---|---|
Microsoft.Authorization/*/read | Any read operation on anything under Microsoft.Authorization |
Microsoft.Insights/alertRules/* | Every operation under Microsoft.Insights/alertRules |
Microsoft.Insights/generateLiveToken/read | Live Metrics get token |
Microsoft.Insights/metricAlerts/* | Every operation under Microsoft.Insights/metricAlerts |
Microsoft.Insights/components/* | Every operation under Microsoft.Insights/components |
Microsoft.Insights/scheduledqueryrules/* | Every operation under Microsoft.Insights/scheduledqueryrules |
Microsoft.Insights/topology/read | Read Topology |
Microsoft.Insights/transactions/read | Read Transactions |
Microsoft.Insights/webtests/* | Every operation under Microsoft.Insights/webtests |
Microsoft.ResourceHealth/availabilityStatuses/read | Gets the availability statuses for all resources in the specified scope |
Microsoft.Resources/deployments/* | Every operation under Microsoft.Resources/deployments |
Microsoft.Resources/subscriptions/resourceGroups/read | Gets or lists resource groups. |
Microsoft.Support/* | Every operation under Microsoft.Support |
Assign it
Scope it as tightly as you can: a resource or resource group rather than the whole subscription.
az role assignment create \
--assignee "jane.doe@contoso.com" \
--role "Application Insights Component Contributor" \
--scope "/subscriptions/<subscription id>/resourceGroups/<resource group>"New-AzRoleAssignment -SignInName "jane.doe@contoso.com" `
-RoleDefinitionName "Application Insights Component Contributor" `
-Scope "/subscriptions/<subscription id>/resourceGroups/<resource group>"resource assignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = {
name: guid(resourceGroup().id, principalId, 'ae349356-3a1b-4a5e-921d-050484c6347e')
properties: {
roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'ae349356-3a1b-4a5e-921d-050484c6347e')
principalId: principalId
}
}Who already has it?
authorizationresources
| where type == "microsoft.authorization/roleassignments"
| where tostring(properties.roleDefinitionId) endswith "ae349356-3a1b-4a5e-921d-050484c6347e"
| project principalId = tostring(properties.principalId), principalType = tostring(properties.principalType), scope = tostring(properties.scope)Other monitor roles
- Grafana Admin · 1 permission
- Grafana Editor · 1 permission
- Grafana Limited Viewer · 1 permission
- Grafana Viewer · 1 permission
- Log Analytics Data Reader · 3 permissions
- Monitoring Reader · 3 permissions
- Workbook Reader · 3 permissions
- Data Purger · 4 permissions