Skip to content

Commit d03303a

Browse files
committed
monitoring: grant grafana read access to all configmaps
1 parent 9445499 commit d03303a

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed

monitoring/grafana-role.yaml

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Grafana sidecar needs to be able to query configmaps across all namespaces
2+
kind: ClusterRoleBinding
3+
apiVersion: rbac.authorization.k8s.io/v1
4+
metadata:
5+
name: grafana-clusterrolebinding
6+
roleRef:
7+
kind: ClusterRole
8+
name: grafana-clusterrole
9+
apiGroup: rbac.authorization.k8s.io
10+
subjects:
11+
- kind: ServiceAccount
12+
name: grafana
13+
---
14+
kind: ClusterRole
15+
apiVersion: rbac.authorization.k8s.io/v1
16+
metadata:
17+
name: grafana-clusterrole
18+
rules:
19+
- apiGroups: [""]
20+
resources: ["configmaps"]
21+
verbs: ["get", "watch", "list"]

monitoring/kustomization.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ resources:
77
- ./loki
88
- ./promtail
99
- prometheus-additional-targets.yaml
10+
- grafana-role.yaml
1011
patches:
1112
- container-images.patch.yaml
1213
- cluster-wide.patch.yaml

0 commit comments

Comments
 (0)