From fc1e6300fe3894884f9b1f300f691d6d48e0f8bf Mon Sep 17 00:00:00 2001 From: Christopher Tate Date: Wed, 6 Dec 2023 14:00:52 -0700 Subject: [PATCH] ClusterRoleBinding for grafana-serviceaccount to cluster-monitoring-view --- ...afana-serviceaccount-cluster-monitoring-view.yaml | 12 ++++++++++++ grafana/base/clusterrolebindings/kustomization.yaml | 5 +++++ grafana/base/kustomization.yaml | 1 + 3 files changed, 18 insertions(+) create mode 100644 grafana/base/clusterrolebindings/grafana-serviceaccount-cluster-monitoring-view.yaml create mode 100644 grafana/base/clusterrolebindings/kustomization.yaml diff --git a/grafana/base/clusterrolebindings/grafana-serviceaccount-cluster-monitoring-view.yaml b/grafana/base/clusterrolebindings/grafana-serviceaccount-cluster-monitoring-view.yaml new file mode 100644 index 00000000..c2534d98 --- /dev/null +++ b/grafana/base/clusterrolebindings/grafana-serviceaccount-cluster-monitoring-view.yaml @@ -0,0 +1,12 @@ +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: grafana-serviceaccount-cluster-monitoring-view +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: cluster-monitoring-view +subjects: +- kind: ServiceAccount + name: grafana-serviceaccount + namespace: grafana diff --git a/grafana/base/clusterrolebindings/kustomization.yaml b/grafana/base/clusterrolebindings/kustomization.yaml new file mode 100644 index 00000000..fd973d2f --- /dev/null +++ b/grafana/base/clusterrolebindings/kustomization.yaml @@ -0,0 +1,5 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization + +resources: + - grafana-serviceaccount-cluster-monitoring-view.yaml diff --git a/grafana/base/kustomization.yaml b/grafana/base/kustomization.yaml index 89790cc5..e408c25e 100644 --- a/grafana/base/kustomization.yaml +++ b/grafana/base/kustomization.yaml @@ -4,6 +4,7 @@ resources: - operatorgroups - subscriptions - routes + - clusterrolebindings commonLabels: app.kubernetes.io/name: grafana app.kubernetes.io/component: grafana