Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/kube-state-metrics/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ keywords:
- prometheus
- kubernetes
type: application
version: 6.1.0
version: 6.1.1
# renovate: github-releases=kubernetes/kube-state-metrics
appVersion: 2.16.0
home: https://github.com/kubernetes/kube-state-metrics/
Expand Down
60 changes: 36 additions & 24 deletions charts/kube-state-metrics/templates/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,24 @@ rules:
- certificatesigningrequests
verbs: ["list", "watch"]
{{ end -}}
{{ if has "clusterroles" $.Values.collectors }}
- apiGroups: ["rbac.authorization.k8s.io"]
resources:
- clusterroles
verbs: ["list", "watch"]
{{ end -}}
{{ if has "configmaps" $.Values.collectors }}
- apiGroups: [""]
resources:
- configmaps
verbs: ["list", "watch"]
{{ end -}}
{{ if has "clusterrolebindings" $.Values.collectors }}
- apiGroups: ["rbac.authorization.k8s.io"]
resources:
- clusterrolebindings
verbs: ["list", "watch"]
{{ end -}}
{{ if has "cronjobs" $.Values.collectors }}
- apiGroups: ["batch"]
resources:
Expand Down Expand Up @@ -69,6 +81,12 @@ rules:
- ingresses
verbs: ["list", "watch"]
{{ end -}}
{{ if has "ingressclasses" $.Values.collectors }}
- apiGroups: ["networking.k8s.io"]
resources:
- ingressclasses
verbs: ["list", "watch"]
{{ end -}}
{{ if has "jobs" $.Values.collectors }}
- apiGroups: ["batch"]
resources:
Expand Down Expand Up @@ -105,30 +123,6 @@ rules:
- networkpolicies
verbs: ["list", "watch"]
{{ end -}}
{{ if has "ingressclasses" $.Values.collectors }}
- apiGroups: ["networking.k8s.io"]
resources:
- ingressclasses
verbs: ["list", "watch"]
{{ end -}}
{{ if has "clusterrolebindings" $.Values.collectors }}
- apiGroups: ["rbac.authorization.k8s.io"]
resources:
- clusterrolebindings
verbs: ["list", "watch"]
{{ end -}}
{{ if has "clusterroles" $.Values.collectors }}
- apiGroups: ["rbac.authorization.k8s.io"]
resources:
- clusterroles
verbs: ["list", "watch"]
{{ end -}}
{{ if has "roles" $.Values.collectors }}
- apiGroups: ["rbac.authorization.k8s.io"]
resources:
- roles
verbs: ["list", "watch"]
{{ end -}}
{{ if has "nodes" $.Values.collectors }}
- apiGroups: [""]
resources:
Expand Down Expand Up @@ -177,6 +171,18 @@ rules:
- resourcequotas
verbs: ["list", "watch"]
{{ end -}}
{{ if has "roles" $.Values.collectors }}
- apiGroups: ["rbac.authorization.k8s.io"]
resources:
- roles
verbs: ["list", "watch"]
{{ end -}}
{{ if has "rolebindings" $.Values.collectors }}
- apiGroups: ["rbac.authorization.k8s.io"]
resources:
- rolebindings
verbs: ["list", "watch"]
{{ end -}}
{{ if has "secrets" $.Values.collectors }}
- apiGroups: [""]
resources:
Expand All @@ -195,6 +201,12 @@ rules:
- statefulsets
verbs: ["list", "watch"]
{{ end -}}
{{ if has "serviceaccounts" $.Values.collectors }}
- apiGroups: [""]
resources:
- serviceaccounts
verbs: ["list", "watch"]
{{ end -}}
{{ if has "storageclasses" $.Values.collectors }}
- apiGroups: ["storage.k8s.io"]
resources:
Expand Down
11 changes: 7 additions & 4 deletions charts/kube-state-metrics/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -396,13 +396,17 @@ metricAnnotationsAllowList: []
# By default, all available resources are enabled, comment out to disable.
collectors:
- certificatesigningrequests
# - clusterroles
- configmaps
# - clusterrolebindings
- cronjobs
- daemonsets
- deployments
- endpoints
# - endpointslices
- horizontalpodautoscalers
- ingresses
# - ingressclasses
- jobs
- leases
- limitranges
Expand All @@ -417,16 +421,15 @@ collectors:
- replicasets
- replicationcontrollers
- resourcequotas
# - roles
# - rolebindings
- secrets
- services
# - serviceaccounts
- statefulsets
- storageclasses
- validatingwebhookconfigurations
- volumeattachments
# - ingressclasses
# - clusterrolebindings
# - clusterroles
# - roles

# Enabling kubeconfig will pass the --kubeconfig argument to the container
kubeconfig:
Expand Down