# --- # # config file version # apiVersion: 2 # # list of roles to insert/update/delete # roles: # # name of the role you want to create or update. Required. # - name: 'custom:users:writer' # # uid of the role. Has to be unique for all orgs. # uid: customuserswriter1 # # description of the role, informative purpose only. # description: 'Create, read, write users' # # version of the role, Grafana will update the role when increased. # version: 2 # # org id. Defaults to Grafana's default if not specified. # orgId: 1 # # list of the permissions granted by this role. # permissions: # # action allowed. # - action: 'users:read' # # scope it applies to. # scope: 'users:*' # - action: 'users:write' # scope: 'users:*' # - action: 'users:create' # - name: 'custom:global:users:reader' # # overwrite org id and creates a global role. # global: true # # state of the role. Defaults to 'present'. If 'absent', role will be deleted. # state: 'absent' # # force deletion revoking all grants of the role. # force: true # - uid: 'basic_editor' # version: 2 # global: true # # list of roles to copy permissions from. # from: # - uid: 'basic_editor' # global: true # - name: 'fixed:users:writer' # global: true # # list of the permissions to add/remove on top of the copied ones. # permissions: # - action: 'users:read' # scope: 'users:*' # - action: 'users:write' # scope: 'users:*' # # state of the permission. Defaults to 'present'. If 'absent', the permission will be removed. # state: absent # # list role assignments to teams to create or remove. # teams: # # name of the team you want to assign roles to. Required. # - name: 'Users writers' # # org id. Will default to Grafana's default if not specified. # orgId: 1 # # list of roles to assign to the team # roles: # # uid of the role you want to assign to the team. # - uid: 'customuserswriter1' # # org id. Will default to Grafana's default if not specified. # orgId: 1 # # name of the role you want to assign to the team. # - name: 'fixed:users:writer' # # overwrite org id to specify the role is global. # global: true # # state of the assignment. Defaults to 'present'. If 'absent', the assignment will be revoked. # state: absent