1# Default values for kube-state-metrics.
5 repository: chainguard-private/kube-state-metrics
6 # If unset use v + .Charts.appVersion
8 sha: sha256:e8a015a543daa0c9c061fd3cdc677e874d327d51955d61bc4090c4f3756a8e80
9 pullPolicy: IfNotPresent
11# - name: "image-pull-secret"
14 # To help compatibility with other charts which use global.imagePullSecrets.
15 # Allow either an array of {name: pullSecret} maps (k8s-style), or an array of strings (more common helm-style).
27 # Allow parent charts to override registry hostname
29# Provide a name in place of kube-state-metrics for `app.kubernetes.io/name` labels.
31# Provide a name to substitute for the full names of resources.
33# If set to true, this will deploy kube-state-metrics as a StatefulSet and the data
34# will be automatically sharded across <.Values.replicas> pods using the built-in
35# autodiscovery feature: https://github.com/kubernetes/kube-state-metrics#automated-sharding
36# This is an experimental feature and there are no stability guarantees.
40# Change the deployment strategy when autosharding is disabled.
41# ref: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy
42# The default is "RollingUpdate" as per Kubernetes defaults.
43# During a release, 'RollingUpdate' can lead to two running instances for a short period of time while 'Recreate' can create a small gap in data.
44# updateStrategy: Recreate
46# Number of old history to retain to allow rollback
47# Default Kubernetes value is set to 10
48revisionHistoryLimit: 10
49# List of additional cli arguments to configure kube-state-metrics
50# for example: --log_file, --auto-gomemlimit, etc.
51# all the possible args can be found here: https://github.com/kubernetes/kube-state-metrics/blob/main/docs/developer/cli-arguments.md
53# Gzip responses to scrapes that accept the encoding.
54enableGzipEncoding: false
55# If false then the user will opt out of automounting API credentials. kube-state-metrics still needs
56# credentials to reach the API server: supply them with kubeconfig.enabled below, or mount a projected
57# serviceAccountToken volume at /var/run/secrets/kubernetes.io/serviceaccount yourself.
58automountServiceAccountToken: true
61 # Default to clusterIP for backward compatibility
65 ipFamilies: ["IPv6", "IPv4"]
66 ipFamilyPolicy: "PreferDualStack"
69 # Only allow access to the loadBalancerIP from these IPs
70 loadBalancerSourceRanges: []
73## Additional labels to add to all resources
75# app: kube-state-metrics
77## Override selector labels
79## set to true to add the release label so scraping of the servicemonitor with kube-prometheus-stack works out of the box
82## Use the host's user namespace for deployment.
83## ref: https://kubernetes.io/docs/tasks/configure-pod-container/user-namespaces/
86 # If true, create & use RBAC resources
88 # Set to false only when the customresourcedefinitions list/watch permission is
89 # granted to the ServiceAccount by other means (e.g. a cluster-scoped ClusterRole
90 # managed outside this chart). kube-state-metrics always needs it for
91 # customResourceState; this only controls whether the chart creates the rule.
93 createClusterRoleRules: true
94 # Set to a rolename to use existing role - skipping role creating - but still doing serviceaccount and rolebinding to it, rolename set here.
95 # useExistingRole: your-existing-role
97 # If set to false - Run without Cluteradmin privs needed - ONLY works if namespace is also set (if useExistingRole is set this name is used as ClusterRole or Role to bind to)
99 # Add permissions for CustomResources' apiGroups in Role/ClusterRole. Should be used in conjunction with Custom Resource State Metrics configuration
101 # - apiGroups: ["monitoring.coreos.com"]
102 # resources: ["prometheuses"]
103 # verbs: ["list", "watch"]
105 # Aggregate ClusterRoles using label selectors (only applies when useClusterRole: true).
106 # When set, this ClusterRole aggregates matching ClusterRoles instead of defining rules
107 # directly, so the built-in collector rules above are NOT included. Make sure the
108 # aggregated ClusterRoles grant the permissions kube-state-metrics needs.
109 # ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/#aggregated-clusterroles
111 # clusterRoleSelectors:
113 # rbac.example.com/aggregate-to-monitoring: "true"
114 clusterRoleSelectors: []
115# Enable kube-state-metrics native request authn/authz on the metrics endpoints
116# via the `--auth-filter` flag, as an alternative to running kube-rbac-proxy.
117# When enabled, the `create` permissions on `tokenreviews` and
118# `subjectaccessreviews` required by the filter are added to the (Cluster)Role
119# automatically. Scrapers must authenticate; see the chart README and the
120# kube-state-metrics docs on protecting metrics endpoints.
123# Configure kube-rbac-proxy. When enabled, creates one kube-rbac-proxy container per HTTP endpoint (metrics and telemetry).
124# The telemetry one is created even with selfMonitor disabled, as the readiness probe needs it; selfMonitor only exposes it on the service.
125# The requests are served through the same service but requests are then HTTPS.
130 repository: chainguard-private/kube-rbac-proxy
132 sha: sha256:ceb73081cf1f2eee5de748f8cab54af4b447a9dc6057a1a1f506b81601202680
133 pullPolicy: IfNotPresent
134 # This set --ignore-paths=/healthz,/livez,/readyz to kubeRBACProxy container args
135 # to allow the pod probes working properly with kubeRBACProxy enabled.
136 ignoreProbePaths: true
137 # List of additional cli arguments to configure kube-rbac-prxy
138 # for example: --tls-cipher-suites, --log-file, etc.
139 # all the possible args can be found here: https://github.com/brancz/kube-rbac-proxy#usage
141 ## Specify security settings for a Container
142 ## Allows overrides and additional options compared to (Pod) securityContext
143 ## Ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container
144 containerSecurityContext:
145 readOnlyRootFilesystem: true
146 allowPrivilegeEscalation: false
150 # Configure specific upstream port for kube-state-metrics container
152 # Configure specific proxy endpoints port
153 # This port is for healthz on readinessProbe kube-rbac-proxy-http container
154 proxyEndpointsPort: 8888
155 # Configure specific proxy endpoints port of the kube-rbac-proxy-telemetry container
156 # It must differ from proxyEndpointsPort, as both containers share the pod network
157 telemetryProxyEndpointsPort: 8889
159 # We usually recommend not to specify default resources and to leave this as a conscious
160 # choice for the user. This also increases chances charts run on environments with little
161 # resources, such as Minikube. If you do want to specify resources, uncomment the following
162 # lines, adjust them as necessary, and remove the curly braces after 'resources:'.
170 ## volumeMounts enables mounting custom volumes in rbac-proxy containers
171 ## Useful for TLS certificates and keys
173 # - mountPath: /etc/tls
174 # name: kube-rbac-proxy-tls
177 # Specifies whether a ServiceAccount should be created, require rbac true
179 # The name of the ServiceAccount to use.
180 # If not set and create is true, a name is generated using the fullname template
182 # Reference to one or more secrets to be used when pulling images
183 # ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
185 # ServiceAccount annotations.
186 # Use case: AWS EKS IAM roles for service accounts
187 # ref: https://docs.aws.amazon.com/eks/latest/userguide/specify-service-account-role.html
189 # If false then the user will opt out of automounting API credentials.
190 automountServiceAccountToken: true
191# Additional Environment variables
196# resource: limits.cpu
204 namespaceSelector: []
208 ## SampleLimit defines per-scrape limit on number of scraped samples that will be accepted.
211 ## TargetLimit defines a limit on the number of scraped targets that will be accepted.
214 ## Per-scrape limit on number of labels that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
217 ## Per-scrape limit on length of labels name that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
219 labelNameLengthLimit: 0
220 ## Per-scrape limit on length of labels value that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
222 labelValueLengthLimit: 0
224 ## kube-state-metrics endpoint
229 ## Whether to enable HTTP2 for servicemonitor
232 metricRelabelings: []
235 ## File to read bearer token for scraping targets
237 ## Secret to mount to read bearer token for scraping targets. The secret needs
238 ## to be in the same namespace as the service monitor and accessible by the
239 ## Prometheus Operator
240 bearerTokenSecret: {}
244 ## selfMonitor endpoint
249 ## Whether to enable HTTP2 for servicemonitor
252 metricRelabelings: []
255 ## File to read bearer token for scraping targets
257 ## Secret to mount to read bearer token for scraping targets. The secret needs
258 ## to be in the same namespace as the service monitor and accessible by the
259 ## Prometheus Operator
260 bearerTokenSecret: {}
264 ## Create a scrapeConfig resource for scraping the kube-state-metrics service. Use this instead of serviceMonitor
265 ## to have more instances of kube-state-metrics safety.
267 ## To avoid duplicate metrics, first disable the serviceMonitor creation via prometheus.monitor.enabled=false
271 jobName: kube-state-metrics
272 ## SampleLimit defines per-scrape limit on number of scraped samples that will be accepted.
275 ## TargetLimit defines a limit on the number of scraped targets that will be accepted.
278 ## Per-scrape limit on number of labels that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
281 ## Per-scrape limit on length of labels name that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
283 labelNameLengthLimit: 0
284 ## Per-scrape limit on length of labels value that will be accepted for a sample. Only valid in Prometheus versions 2.27.0 and newer.
286 labelValueLengthLimit: 0
287 ## StaticConfigLabels defines the labels to be used in the Prometheus static configuration for scraping.
288 staticConfigLabels: {}
292 ## Whether to enable HTTP2 for scrapeconfig
295 metricRelabelings: []
299## Configure network policy for kube-state-metrics
308 # app.kubernetes.io/name: kube-state-metrics
317## Specify security settings for a Container
318## Allows overrides and additional options compared to (Pod) securityContext
319## Ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container
320containerSecurityContext:
321 readOnlyRootFilesystem: true
322 allowPrivilegeEscalation: false
326## Node labels for pod assignment
327## Ref: https://kubernetes.io/docs/user-guide/node-selection/
329## Affinity settings for pod assignment
330## Can be defined as either a dict or string. String is useful for `tpl` templating.
331## Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/
335# requiredDuringSchedulingIgnoredDuringExecution:
338# {{- include "kube-state-metrics.selectorLabels" . | indent 10 }}
339# topologyKey: kubernetes.io/hostname
341## Tolerations for pod assignment
342## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
344## Topology spread constraints for pod assignment
345## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/
346topologySpreadConstraints: []
347# Annotations to be added to the deployment/statefulset
349# Labels to be added to the deployment/statefulset
351# Annotations to be added to the pod
353# Labels to be added to the pod
355## Assign a PriorityClassName to pods if set
356# priorityClassName: ""
358# Ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb/
359podDisruptionBudget: {}
360# Comma-separated list of metrics to be exposed.
361# This list comprises of exact metric names and/or regex patterns.
362# The allowlist and denylist are mutually exclusive.
364# Comma-separated list of metrics not to be enabled.
365# This list comprises of exact metric names and/or regex patterns.
366# The allowlist and denylist are mutually exclusive.
368# Comma-separated list of metrics which are opt-in and not enabled by default.
369# This is applied in addition to the allowlist and denylist above.
371# Comma-separated list of additional Kubernetes label keys that will be used in the resource's
372# labels metric. By default the metric contains only name and namespace labels.
373# To include additional labels, provide a list of resource names in their plural form and Kubernetes
374# label keys you would like to allow for them (Example: '=namespaces=[k8s-label-1,k8s-label-n,...],pods=[app],...)'.
375# A single '*' can be provided per resource instead to allow any labels, but that has
376# severe performance implications (Example: '=pods=[*]').
377metricLabelsAllowlist: []
378# - namespaces=[k8s-label-1,k8s-label-n]
380# Comma-separated list of Kubernetes annotations keys that will be used in the resource'
381# labels metric. By default the metric contains only name and namespace labels.
382# To include additional annotations provide a list of resource names in their plural form and Kubernetes
383# annotation keys you would like to allow for them (Example: '=namespaces=[kubernetes.io/team,...],pods=[kubernetes.io/team],...)'.
384# A single '*' can be provided per resource instead to allow any annotations, but that has
385# severe performance implications (Example: '=pods=[*]').
386metricAnnotationsAllowList: []
387# - pods=[k8s-annotation-1,k8s-annotation-n]
389# Collectors enabled by default. Comment out entries to disable them.
390# Additional opt-in collectors are listed below.
392 - certificatesigningrequests
398 - horizontalpodautoscalers
403 - mutatingwebhookconfigurations
407 - persistentvolumeclaims
409 - poddisruptionbudgets
412 - replicationcontrollers
418 - validatingwebhookconfigurations
421 # - clusterrolebindings
426 # Admission policy collectors require kube-state-metrics v2.20.0 or later.
427 # These validating admission policy collectors require Kubernetes v1.30+.
428 # - validatingadmissionpolicies
429 # - validatingadmissionpolicybindings
430 # These mutating admission policy collectors require Kubernetes v1.36+.
431 # - mutatingadmissionpolicies
432 # - mutatingadmissionpolicybindings
433# collectorsExclude / collectorsExtra tweak the default `collectors` list above
434# without redefining it. Both operate on `.Values.collectors` (not on KSM's
435# built-in defaults): with `collectors: []` there is nothing to layer onto and
436# `collectorsExtra` becomes the entire --resources list.
437# collectorsExclude removes entries from the list:
440# collectorsExtra appends entries after exclusion (deduplicated):
444# Enabling kubeconfig will pass the --kubeconfig argument to the container
447 # base64 encoded kube-config file
449# Enabling support for customResourceState, will create a configMap including your config that will be read from kube-state-metrics
451 # Whether to enable support for CustomResourceStateMetrics.
453 # Whether to create the ConfigMap that holds the config.
455 # Name of the ConfigMap that holds the config. If empty, name will be generated based on the release name.
457 # ConfigMap key that holds the config.
459 # Definition of the CustomResourceStateMetrics. Add (Cluster)Role permissions to list/watch the resources defined in the config to rbac.extraRules.
461# Enable only the release namespace for collecting resources. By default all namespaces are collected.
462# If releaseNamespace and namespaces are both set a merged list will be collected.
463releaseNamespace: false
464# Comma-separated list(string) or yaml list of namespaces to be enabled for collecting resources. By default all namespaces are collected.
466# Comma-separated list of namespaces not to be enabled. If namespaces and namespaces-denylist are both set,
467# only namespaces that are excluded in namespaces-denylist will be used.
468namespacesDenylist: ""
469# Only collect pods that are not assigned to a node yet. This applies a spec.nodeName= field
470# selector to every enabled collector, so it belongs in a dedicated release with collectors set
471# to [pods]. On a default install it drops the metrics of all scheduled pods. Experimental.
472trackUnscheduledPods: false
473## Override the deployment namespace
477# We usually recommend not to specify default resources and to leave this as a conscious
478# choice for the user. This also increases chances charts run on environments with little
479# resources, such as Minikube. If you do want to specify resources, uncomment the following
480# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
488# Enable self metrics configuration for service and Service Monitor
489# Default values for telemetry configuration can be overridden
490# If you set telemetryNodePort, you must also set service.type to NodePort
493 # telemetryHost: 0.0.0.0
494 # telemetryPort: 8081
495 # telemetryNodePort: 0
496# Enable vertical pod autoscaler support for kube-state-metrics
497verticalPodAutoscaler:
499 # Recommender responsible for generating recommendation for the object.
500 # List should be empty (then the default recommender will generate the recommendation)
501 # or contain exactly one recommender.
503 # - name: custom-recommender-performance
505 # List of resources that the vertical pod autoscaler can control. Defaults to cpu and memory
506 controlledResources: []
507 # Specifies which resource values should be controlled: RequestsOnly or RequestsAndLimits.
508 # controlledValues: RequestsAndLimits
510 # Define the max allowed resources for the pod
514 # Define the min allowed resources for the pod
519# Specifies minimal number of replicas which need to be alive for VPA Updater to attempt pod eviction
521# Specifies whether recommended updates are applied when a Pod is started and whether recommended updates
522# are applied during the life of a Pod. Possible values are "Off", "Initial", "Recreate", and "Auto".
525# volumeMounts are used to add custom volume mounts to deployment.
528# - mountPath: /etc/config
531# volumes are used to add custom volumes to deployment
538# Extra manifests to deploy as an array
544# name: prometheus-extra
548## Containers allows injecting additional containers.
551# image: kiwigrid/k8s-sidecar:latest
553## InitContainers allows injecting additional initContainers.
556# image: kiwigrid/k8s-sidecar:latest
558## dnsPolicy allows to change the default DNS configuration for the pod
559## Ref: https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy
560dnsPolicy: ClusterFirst
561## dnsConfig allows setting up specific DNS configuration for the pod
562## Ref: https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-dns-config
564## Settings for startup, liveness and readiness probes
565## Ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
568## Startup probe can optionally be enabled.
576 initialDelaySeconds: 0
587 initialDelaySeconds: 5
598 initialDelaySeconds: 5