Skip to content

Commit

Permalink
[stable/kube-state-metrics] Add missing permission for volumeattachme…
Browse files Browse the repository at this point in the history
…nts collector (helm#21079)

When enabling the volumeattachments collector, the following error is
logged without this permission:

Failed to list *v1.VolumeAttachment: volumeattachments.storage.k8s.io is forbidden: User "XXXXX:kube-state-metrics" cannot list resource "volumeattachments" in API group "storage.k8s.io" at the cluster scope

Signed-off-by: Fabrice Rabaute <fabrice@arista.com>
  • Loading branch information
jfrabaute authored and includerandom committed Jul 19, 2020
1 parent 342ce49 commit f5da670
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion stable/kube-state-metrics/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ keywords:
- monitoring
- prometheus
- kubernetes
version: 2.7.1
version: 2.7.2
appVersion: 1.9.5
home: https://github.com/kubernetes/kube-state-metrics/
sources:
Expand Down
4 changes: 2 additions & 2 deletions stable/kube-state-metrics/templates/clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -166,9 +166,9 @@ rules:
verbs: ["list", "watch"]
{{ end -}}
{{ if .Values.collectors.volumeattachments }}
- apiGroups: ["storageclasses.k8s.io"]
- apiGroups: ["storage.k8s.io"]
resources:
- storageclasses
- volumeattachments
verbs: ["list", "watch"]
{{ end -}}
{{ if .Values.collectors.verticalpodautoscalers }}
Expand Down

0 comments on commit f5da670

Please sign in to comment.