RBAC: Update plugin.json roles, includes and routes (#80592)
* RBAC: Update plugin.json roles, includes and routes * action -> reqAction
This commit is contained in:
@@ -272,6 +272,10 @@
|
|||||||
"description": "The minimum role a user must have to see this page in the navigation menu.",
|
"description": "The minimum role a user must have to see this page in the navigation menu.",
|
||||||
"enum": ["Admin", "Editor", "Viewer"]
|
"enum": ["Admin", "Editor", "Viewer"]
|
||||||
},
|
},
|
||||||
|
"action": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "The RBAC action a user must have to see this page in the navigation menu."
|
||||||
|
},
|
||||||
"path": {
|
"path": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"description": "Used for app plugins."
|
"description": "Used for app plugins."
|
||||||
@@ -353,6 +357,10 @@
|
|||||||
"reqRole": {
|
"reqRole": {
|
||||||
"type": "string"
|
"type": "string"
|
||||||
},
|
},
|
||||||
|
"reqAction": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "The RBAC action a user must have to use this route."
|
||||||
|
},
|
||||||
"headers": {
|
"headers": {
|
||||||
"type": "array",
|
"type": "array",
|
||||||
"description": "For data source plugins. Route headers adds HTTP headers to the proxied request."
|
"description": "For data source plugins. Route headers adds HTTP headers to the proxied request."
|
||||||
@@ -525,6 +533,54 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"roles": {
|
||||||
|
"type": "array",
|
||||||
|
"description": "List of RBAC roles and their default assignments.",
|
||||||
|
"items": {
|
||||||
|
"type": "object",
|
||||||
|
"additionalProperties": false,
|
||||||
|
"properties": {
|
||||||
|
"role": {
|
||||||
|
"type": "object",
|
||||||
|
"description": "RBAC role definition to bundle related RBAC permissions on the plugin.",
|
||||||
|
"additionalProperties": false,
|
||||||
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Display name of the role."
|
||||||
|
},
|
||||||
|
"description": {
|
||||||
|
"type": "string",
|
||||||
|
"description": "Describe the aim of the role."
|
||||||
|
},
|
||||||
|
"permissions": {
|
||||||
|
"type": "array",
|
||||||
|
"description": "RBAC permission on the plugin.",
|
||||||
|
"items": {
|
||||||
|
"type": "object",
|
||||||
|
"additionalProperties": false,
|
||||||
|
"properties": {
|
||||||
|
"action": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"scope": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"grants": {
|
||||||
|
"type": "array",
|
||||||
|
"description": "Default assignments of the role to Grafana basic roles (Viewer, Editor, Admin, Grafana Admin)",
|
||||||
|
"items": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user