Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to add new Role using Helm #3040

Open
rlugovyy opened this issue Mar 24, 2024 · 0 comments
Open

How to add new Role using Helm #3040

rlugovyy opened this issue Mar 24, 2024 · 0 comments

Comments

@rlugovyy
Copy link

rlugovyy commented Mar 24, 2024

Hello. How can I add new roles to Grafana via helm? I found [section](https://grafana.com/docs/grafana/latest/administration/roles-and-permissions/access-control/manage-rbac-roles/#:~:text=Create%20custom%20roles%20using%20the%20HTTP%20API&text=For%20example%2C%20if%20you%20only,users%3Acreate%20action%20to%20it.&text=Refer%20to%20the%20RBAC%20HTTP%20API%20for%20more%20details.,-Update%20basic%20role) in the doc where man need to add a configmap for the role. I did this

-templates/role.configmap.yaml

apiVersion: v1
kind: ConfigMap
metadata:
  name: grafana-custom-editor-role
data:
  customrole.yaml: |
    apiVersion: 2

    roles:
      - name: custom:users
        description: 'List, create, or update other users.'
        version: 1
        orgId: 1
        permissions:
          - action: 'users:read'
            scope: 'global.users:*'
          - action: 'users:write'
            scope: 'global.users:*'
          - action: 'users:create'

-values.yaml

grafana:
  extraConfigmapMounts:
  - name: grafana-custom-editor-role
    mountPath: /etc/grafana/provisioning/access-control
    configMap: grafana-custom-editor-role
    readOnly: true

but it doesnt work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant