You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
32 lines
769 B
32 lines
769 B
package manager
|
|
|
|
import (
|
|
"github.com/grafana/grafana/pkg/services/accesscontrol"
|
|
"github.com/grafana/grafana/pkg/services/serviceaccounts"
|
|
)
|
|
|
|
var (
|
|
role = accesscontrol.RoleRegistration{
|
|
Role: accesscontrol.RoleDTO{
|
|
Version: 3,
|
|
Name: "fixed:serviceaccounts:writer",
|
|
DisplayName: "Service accounts writer",
|
|
Description: "Create, delete, read, or query service accounts.",
|
|
Group: "Service accounts",
|
|
Permissions: []accesscontrol.Permission{
|
|
{
|
|
Action: serviceaccounts.ActionRead,
|
|
Scope: serviceaccounts.ScopeAll,
|
|
},
|
|
{
|
|
Action: serviceaccounts.ActionCreate,
|
|
},
|
|
{
|
|
Action: serviceaccounts.ActionDelete,
|
|
Scope: serviceaccounts.ScopeAll,
|
|
},
|
|
},
|
|
},
|
|
Grants: []string{"Admin"},
|
|
}
|
|
)
|
|
|