RBAC: remove redundant role name field from plugin role registrations (#58166)
* RBAC: Remove name from role registration * Inline accesscontrol service * test fix * use fmt Co-Authored-By: marefr <marcus.efraimsson@gmail.com> Co-authored-by: marefr <marcus.efraimsson@gmail.com>
This commit is contained in:
co-authored by
marefr
parent
80e80221b9
commit
d999b5bda0
@@ -158,7 +158,7 @@ seqs: [
|
||||
// Example: the role 'Schedules Reader' bundles permissions to view all schedules of the plugin.
|
||||
#Role: {
|
||||
name: string,
|
||||
displayName: string,
|
||||
name: =~"^([A-Z][0-9A-Za-z ]+)$"
|
||||
description: string,
|
||||
permissions: [...#Permission]
|
||||
}
|
||||
|
||||
@@ -537,7 +537,6 @@ type ReleaseState string
|
||||
// Equivalent Go types at stable import paths are provided in https://github.com/grafana/grok.
|
||||
type Role struct {
|
||||
Description string `json:"description"`
|
||||
DisplayName string `json:"displayName"`
|
||||
Name string `json:"name"`
|
||||
Permissions []struct {
|
||||
Action string `json:"action"`
|
||||
@@ -562,7 +561,6 @@ type RoleRegistration struct {
|
||||
// RBAC role definition to bundle related RBAC permissions on the plugin.
|
||||
Role struct {
|
||||
Description string `json:"description"`
|
||||
DisplayName string `json:"displayName"`
|
||||
Name string `json:"name"`
|
||||
Permissions []struct {
|
||||
Action string `json:"action"`
|
||||
|
||||
Reference in New Issue
Block a user