1# Default values for victoria-metrics.
2# This is a YAML-formatted file.
3# Declare variables to be passed into your templates.
5 # -- Image pull secrets, that can be shared across multiple helm charts
8 # -- Image registry, that can be shared across multiple helm charts
10 # -- Openshift security context compatibility configuration
13 adaptSecurityContext: "auto"
14 # -- Automount OpenShift service signing CA into the pod
15 automountServiceSigningCA: "auto"
17 # -- K8s cluster domain suffix, uses for building storage pods' FQDN. Details are [here](https://kubernetes.io/docs/tasks/administer-cluster/dns-custom-nameservers/)
18 dnsDomain: cluster.local.
19 # -- Labels added to all resources
21 # -- Annotations added to all resources
24 # -- Enables Role/RoleBinding creation
26 # -- If true and `rbac.enabled`, will deploy a Role/RoleBinding instead of a ClusterRole/ClusterRoleBinding
28 # -- Role/RoleBinding labels
30 # -- Role/RoleBinding annotations
32# -- Override chart name
37 # -- Create service account.
39 # -- The name of the service account to use.
40 # If not set and create is true, a name is generated using the fullname template
42 # -- ServiceAccount labels
44 # -- ServiceAccount annotations
46 # -- Mount API token to pod directly
48# -- See `kubectl explain poddisruptionbudget.spec` for more. Details are [here](https://kubernetes.io/docs/tasks/run-application/configure-pdb/)
51 # -- min number or percentage of pods that can be unavailable
53 # -- max number or percentage of pods that can be unavailable
55 # -- Defines criteria when unhealthy pods should be considered for eviction
56 unhealthyPodEvictionPolicy:
58# -- See `kubectl explain networkpolicy.spec` for more. Details are [here](https://kubernetes.io/docs/concepts/services-networking/network-policies/)
65 # -- Extra labels for NetworkPolicy
67 # -- Extra annotations for NetworkPolicy
70 # -- Enable deployment of server component. Deployed as StatefulSet
72 # -- Override default `app` label name
78 repository: chainguard-private/victoria-metrics
80 tag: 1.152.0@sha256:244e91d1c2d042a15da11abe81bd64148fde177ae0f06f431b633984a8f4e385
81 # Variant of the image tag to use.
84 # -- Image pull policy
85 pullPolicy: IfNotPresent
86 # -- Override default container command. Use when the VictoriaMetrics binary is available at a custom path
88 # -- Image pull secrets
90 # -- Specify pod lifecycle
92 # -- Number of victoriametrics single replicas
94 # -- Name of Priority Class
96 # -- Name of the [RuntimeClass](https://kubernetes.io/docs/concepts/containers/runtime-class/) used to run the pod, e.g. "gvisor"
98 # -- Overrides the full name of server component
100 # -- Data retention period. Possible units character: h(ours), d(ays), w(eeks), y(ears), if no unit character specified - month. The minimum retention period is 24h. See these [docs](https://docs.victoriametrics.com/victoriametrics/single-server-victoriametrics/#retention)
102 # -- HTTP listen address configuration. See https://docs.victoriametrics.com/helm/victoria-metrics-single/#http-listen-address for details.
113 tlsAutocertCacheDir: ""
116 # -- Extra command line arguments for container of component
121 # Enable IPv6 support. Useful for running in IPv6-only Kubernetes clusters
123 # Additional hostPath mounts
124 extraHostPathMounts: []
126 # mountPath: /etc/kubernetes/certs
128 # hostPath: /etc/kubernetes/certs
131 # Extra Volumes for the pod
137 # -- Extra Volume Mounts for the container
138 extraVolumeMounts: []
140 # mountPath: /example
142 # -- Extra containers to run in a pod with VM single
144 #- name: config-reloader
145 # image: reloader-image
147 # -- Init containers for VM single pod
150 # image: victoriametrics/vmrestore:latest
152 # - mountPath: /storage
153 # name: vmstorage-volume
154 # - mountPath: /etc/vm/creds
155 # name: secret-remote-storage-keys
158 # - -storageDataPath=/storage
159 # - -src=s3://your_bucket/folder/latest
160 # - -credsFilePath=/etc/vm/creds/credentials
162 # -- Node tolerations for server scheduling to nodes with taints. Details are [here](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/)
165 # operator: "Equal|Exists"
167 # effect: "NoSchedule|PreferNoSchedule"
169 # -- Custom DNS config for pod. Details are [here](https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-config)
171 # -- Pod's node selector. Details are [here](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector)
176 # -- Additional environment variables (ex.: secret tokens, flags). Check [here](https://docs.victoriametrics.com/victoriametrics/#environment-variables) for more details
178 # -- Specify alternative source for env variables
181 # name: special-config
183 # -- Container workdir
184 containerWorkingDir: ""
185 # -- Use an alternate scheduler, e.g. "stork". Check [here](https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/) for more details
189 # -- Create/use Persistent Volume Claim for server component. Empty dir if false
191 # -- Override Persistent Volume Claim name
193 # -- Array of access modes. Must match those of existing PV or dynamic provisioner. Details are [here](https://kubernetes.io/docs/concepts/storage/persistent-volumes/)
196 # -- VolumeClassAttribute to user for persistent volume
197 volumeAttributesClassName:
198 # -- Persistent volume annotations
202 # -- StorageClass to use for persistent volume. Requires server.persistentVolume.enabled: true. If defined, PVC created automatically
204 # -- Existing Claim name. If defined, PVC must be created manually before volume will be bound
206 # -- Bind Persistent Volume by labels. Must match all labels of targeted PV.
208 # -- Mount path. Server data Persistent Volume mount root path.
212 # -- Size of the volume. Should be calculated based on the metrics you send and retention policy you set.
214 # -- Sts/Deploy additional labels
216 # -- Pod's additional labels
218 # -- Pod's annotations
220 # -- Resource object. Details are [here](https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/)
229 # -- Readiness & Liveness probes
231 # -- Indicates whether the Container is ready to service requests. If the readiness probe fails, the endpoints controller removes the Pod's IP address from the endpoints of all Services that match the Pod. The default state of readiness before the initial delay is Failure. If a Container does not provide a readiness probe, the default state is Success.
234 initialDelaySeconds: 5
238 # -- Indicates whether the Container is running. If the liveness probe fails, the kubelet kills the Container, and the Container is subjected to its restart policy. If a Container does not provide a liveness probe, the default state is Success.
241 initialDelaySeconds: 30
245 # -- Indicates whether the Container is done with potentially costly initialization. If set it is executed first. If it fails Container is restarted. If it succeeds liveness and readiness probes takes over.
247 #failureThreshold: 30
251 # -- Security context to be added to server pods
254 # -- Pod's security context. Details are [here](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/)
258 # -- Enable deployment of ingress for server component
260 # -- Ingress annotations
262 # kubernetes.io/ingress.class: nginx
263 # kubernetes.io/tls-acme: 'true'
265 # -- Ingress extra labels
267 # -- Array of host objects
269 - name: vmsingle.local
273 # -- Array of TLS objects
275 # - secretName: vmselect-ingress-tls
278 # For Kubernetes >= 1.18 you should specify the ingress-controller via the field ingressClassName
279 # See https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/#specifying-the-class-of-an-ingress
280 # ingressClassName: nginx
283 # -- Enable deployment of HTTPRoute for single component
285 # -- HTTPRoute annotations
287 # -- HTTPRoute extra labels
289 # -- HTTPGateway objects refs
291 # -- Array of hostnames
293 # -- Extra rules to prepend to route. This is useful when working with annotation based services.
295 # -- Filters for a default rule in HTTPRoute
297 # -- Matches for a default rule in HTTPRoute
301 value: '{{ dig "extraArgs" "http.pathPrefix" "/" .Values.server }}'
303 # -- Enable automatic creation of backup via vmbackupmanager. vmbackupmanager is part of Enterprise packages
306 # -- VMBackupManager image registry
308 # -- VMBackupManager image repository
309 repository: victoriametrics/vmbackupmanager
310 # -- VMBackupManager image tag
312 # Variant of the image tag to use.
315 # -- Disable hourly backups
317 # -- Disable daily backups
319 # -- Disable weekly backups
321 # -- Disable monthly backups
322 disableMonthly: false
323 # -- Backup destination at S3, GCS or local filesystem. Release name will be included to path!
325 # -- Backups' retention settings
327 # -- Keep last N hourly backups. 0 means delete all existing hourly backups. Specify -1 to turn off
329 # -- Keep last N daily backups. 0 means delete all existing daily backups. Specify -1 to turn off
331 # -- Keep last N weekly backups. 0 means delete all existing weekly backups. Specify -1 to turn off
333 # -- Keep last N monthly backups. 0 means delete all existing monthly backups. Specify -1 to turn off
335 # -- Extra command line arguments for container of component
340 # Extra Volume Mounts for the container
341 extraVolumeMounts: []
343 # mountPath: /example
344 # -- Allows to enable restore options for pod.
345 # Read more [here](https://docs.victoriametrics.com/victoriametrics/vmbackupmanager/#restore-commands)
349 # -- Resource object. Details are [here](https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/)
351 # -- Additional environment variables (ex.: secret tokens, flags). Check [here](https://docs.victoriametrics.com/victoriametrics/#environment-variables)
353 # -- Readiness & Liveness probes
355 # -- VMBackupManager readiness probe
359 initialDelaySeconds: 5
363 # -- VMBackupManager liveness probe
367 initialDelaySeconds: 30
371 # -- VMBackupManager startup probe
376 # -- Service traffic distribution. Details are [here](https://kubernetes.io/docs/concepts/services-networking/service/#traffic-distribution)
377 trafficDistribution: ""
378 # -- Service annotations
382 # -- Service ClusterIP
384 # -- Service external IPs. Details are [here](https://kubernetes.io/docs/concepts/services-networking/service/#external-ips)
386 # -- Service load balancer IP
388 # -- Load balancer source range
389 loadBalancerSourceRanges: []
396 # -- Service external traffic policy. Check [here](https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip) for details
397 externalTrafficPolicy: ""
398 # -- Health check node port for a service. Check [here](https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip) for details
399 healthCheckNodePort: ""
400 # -- Service IP family policy. Check [here](https://kubernetes.io/docs/concepts/services-networking/dual-stack/#services) for details.
402 # -- List of service IP families. Check [here](https://kubernetes.io/docs/concepts/services-networking/dual-stack/#services) for details.
404 # -- VictoriaMetrics mode: deployment, statefulSet
406 # -- [K8s Deployment](https://kubernetes.io/docs/concepts/workloads/controllers/deployment/) specific variables
410 # Must be "Recreate" when we have a persistent volume
412 # -- [K8s StatefulSet](https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/) specific variables
415 # -- Deploy order policy for StatefulSet pods
416 podManagementPolicy: OrderedReady
417 # -- StatefulSet update strategy. Check [here](https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#update-strategies) for details.
419 # type: RollingUpdate
420 # -- Pod's termination grace period in seconds
421 terminationGracePeriodSeconds: 60
423 # -- Enable deployment of Service Monitor for server component. This is Prometheus operator object
425 # -- Service Monitor labels
427 # -- Service Monitor annotations
429 # -- Service Monitor path
431 # -- Basic auth params for Service Monitor
433 # -- Commented. Prometheus scrape interval for server component
436 # -- Commented. Prometheus pre-scrape timeout for server component
438 # -- Commented. HTTP scheme to use for scraping.
440 # -- Commented. TLS configuration to use when scraping the endpoint
442 # insecureSkipVerify: true
443 # -- Service Monitor relabelings
445 # -- Service Monitor metricRelabelings
446 metricRelabelings: []
447 # -- Service Monitor port. Uses primary http item name by default
449 # -- Service Monitor target port. Overrides port when set
451 # -- Global relabel configuration
455 # -- Use existing configmap if specified
456 # otherwise .config values will be used. Relabel config **should** reside under `relabel.yml` key
458 # Scrape configuration for victoriametrics
460 # -- If true scrapes targets, creates config map or use specified one with scrape targets
462 # -- Use existing configmap if specified
463 # otherwise .config values will be used. Scrape config **should** reside under `scrape.yml` key
471 # Scrape rule for scrape victoriametrics
472 - job_name: victoriametrics
474 - targets: ["localhost:8428"]
475 # COPY from Prometheus helm chart https://github.com/helm/charts/blob/master/stable/prometheus/values.yaml
477 # Scrape config for API servers.
479 # Kubernetes exposes API servers as endpoints to the default/kubernetes
480 # service so this uses `endpoints` role and uses relabelling to only keep
481 # the endpoints associated with the default/kubernetes service using the
482 # default named port `https`. This works for single API server deployments as
483 # well as HA API server deployments.
484 - job_name: "kubernetes-apiservers"
485 kubernetes_sd_configs:
487 # Default to scraping over https. If required, just disable this or change to
490 # This TLS & bearer token file config is used to connect to the actual scrape
491 # endpoints for cluster components. This is separate to discovery auth
492 # configuration because discovery & scraping are two separate concerns in
493 # Prometheus. The discovery auth config is automatic if Prometheus runs inside
494 # the cluster. Otherwise, more config options have to be provided within the
495 # <kubernetes_sd_config>.
497 ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
498 # If your node certificates are self-signed or use a different CA to the
499 # master CA, then you need to disable certificate verification. Note that
500 # certificate verification is an integral part of a secure infrastructure
501 # so this should only be disabled in a controlled environment. You can
502 # enable certificate verification by commenting the line below.
504 insecure_skip_verify: true
505 bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
506 # Keep only the default/kubernetes service endpoints for the https port. This
507 # will add targets for each API server which Kubernetes adds an endpoint to
508 # the default/kubernetes service.
510 - source_labels: [__meta_kubernetes_namespace, __meta_kubernetes_service_name, __meta_kubernetes_endpoint_port_name]
512 regex: default;kubernetes;https
513 # Scrape rule using kubernetes service discovery for nodes
514 - job_name: "kubernetes-nodes"
515 # Default to scraping over https. If required, just disable this or change to
518 # This TLS & bearer token file config is used to connect to the actual scrape
519 # endpoints for cluster components. This is separate to discovery auth
520 # configuration because discovery & scraping are two separate concerns in
521 # Prometheus. The discovery auth config is automatic if Prometheus runs inside
522 # the cluster. Otherwise, more config options have to be provided within the
523 # <kubernetes_sd_config>.
525 ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
526 # If your node certificates are self-signed or use a different CA to the
527 # master CA, then you need to disable certificate verification. Note that
528 # certificate verification is an integral part of a secure infrastructure
529 # so this should only be disabled in a controlled environment. You can
530 # enable certificate verification by commenting the line below.
532 insecure_skip_verify: true
533 bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
534 kubernetes_sd_configs:
538 regex: __meta_kubernetes_node_label_(.+)
539 # Scrape rule using kubernetes service discovery for cadvisor
540 - job_name: "kubernetes-nodes-cadvisor"
541 # Default to scraping over https. If required, just disable this or change to
544 # This TLS & bearer token file config is used to connect to the actual scrape
545 # endpoints for cluster components. This is separate to discovery auth
546 # configuration because discovery & scraping are two separate concerns in
547 # Prometheus. The discovery auth config is automatic if Prometheus runs inside
548 # the cluster. Otherwise, more config options have to be provided within the
549 # <kubernetes_sd_config>.
551 ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
552 # If your node certificates are self-signed or use a different CA to the
553 # master CA, then you need to disable certificate verification. Note that
554 # certificate verification is an integral part of a secure infrastructure
555 # so this should only be disabled in a controlled environment. You can
556 # enable certificate verification by commenting the line below.
558 insecure_skip_verify: true
559 bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
560 kubernetes_sd_configs:
562 metrics_path: /metrics/cadvisor
565 regex: __meta_kubernetes_node_label_(.+)
566 - source_labels: [__metrics_path__]
567 target_label: metrics_path
568 # ignore timestamps of cadvisor's metrics by default
569 # more info here https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4697#issuecomment-1656540535
570 honor_timestamps: false
571 # Scrape config for service endpoints.
573 # The relabeling allows the actual service scrape endpoint to be configured
574 # via the following annotations:
576 # * `prometheus.io/scrape`: Only scrape services that have a value of `true`
577 # * `prometheus.io/scheme`: If the metrics endpoint is secured then you will need
578 # to set this to `https` & most likely set the `tls_config` of the scrape config.
579 # * `prometheus.io/path`: If the metrics path is not `/metrics` override this.
580 # * `prometheus.io/port`: If the metrics are exposed on a different port to the
581 # service then set this appropriately.
583 # Scrape rule using kubernetes service discovery for endpoints
584 - job_name: "kubernetes-service-endpoints"
585 kubernetes_sd_configs:
589 source_labels: [__meta_kubernetes_pod_container_init]
591 - action: keep_if_equal
592 source_labels: [__meta_kubernetes_service_annotation_prometheus_io_port, __meta_kubernetes_pod_container_port_number]
593 - source_labels: [__meta_kubernetes_service_annotation_prometheus_io_scrape]
596 - source_labels: [__meta_kubernetes_service_annotation_prometheus_io_scheme]
598 target_label: __scheme__
600 - source_labels: [__meta_kubernetes_service_annotation_prometheus_io_path]
602 target_label: __metrics_path__
604 - source_labels: [__address__, __meta_kubernetes_service_annotation_prometheus_io_port]
606 target_label: __address__
607 regex: ([^:]+)(?::\d+)?;(\d+)
610 regex: __meta_kubernetes_service_label_(.+)
611 - source_labels: [__meta_kubernetes_namespace]
613 target_label: namespace
614 - source_labels: [__meta_kubernetes_service_name]
616 target_label: service
617 - source_labels: [__meta_kubernetes_pod_node_name]
620 # Scrape config for slow service endpoints; same as above, but with a larger
621 # timeout and a larger interval
623 # The relabeling allows the actual service scrape endpoint to be configured
624 # via the following annotations:
626 # * `prometheus.io/scrape-slow`: Only scrape services that have a value of `true`
627 # * `prometheus.io/scheme`: If the metrics endpoint is secured then you will need
628 # to set this to `https` & most likely set the `tls_config` of the scrape config.
629 # * `prometheus.io/path`: If the metrics path is not `/metrics` override this.
630 # * `prometheus.io/port`: If the metrics are exposed on a different port to the
631 # service then set this appropriately.
633 - job_name: "kubernetes-service-endpoints-slow"
636 kubernetes_sd_configs:
640 source_labels: [__meta_kubernetes_pod_container_init]
642 - action: keep_if_equal
643 source_labels: [__meta_kubernetes_service_annotation_prometheus_io_port, __meta_kubernetes_pod_container_port_number]
644 - source_labels: [__meta_kubernetes_service_annotation_prometheus_io_scrape_slow]
647 - source_labels: [__meta_kubernetes_service_annotation_prometheus_io_scheme]
649 target_label: __scheme__
651 - source_labels: [__meta_kubernetes_service_annotation_prometheus_io_path]
653 target_label: __metrics_path__
655 - source_labels: [__address__, __meta_kubernetes_service_annotation_prometheus_io_port]
657 target_label: __address__
658 regex: ([^:]+)(?::\d+)?;(\d+)
661 regex: __meta_kubernetes_service_label_(.+)
662 - source_labels: [__meta_kubernetes_namespace]
664 target_label: namespace
665 - source_labels: [__meta_kubernetes_service_name]
667 target_label: service
668 - source_labels: [__meta_kubernetes_pod_node_name]
671 # Example scrape config for probing services via the Blackbox Exporter.
673 # The relabeling allows the actual service scrape endpoint to be configured
674 # via the following annotations:
676 # * `prometheus.io/probe`: Only probe services that have a value of `true`
678 - job_name: "kubernetes-services"
682 kubernetes_sd_configs:
685 - source_labels: [__meta_kubernetes_service_annotation_prometheus_io_probe]
688 - source_labels: [__address__]
689 target_label: __param_target
690 - target_label: __address__
691 replacement: blackbox
692 - source_labels: [__param_target]
693 target_label: instance
695 regex: __meta_kubernetes_service_label_(.+)
696 - source_labels: [__meta_kubernetes_namespace]
697 target_label: namespace
698 - source_labels: [__meta_kubernetes_service_name]
699 target_label: service
700 # Example scrape config for pods
702 # The relabeling allows the actual pod scrape endpoint to be configured via the
703 # following annotations:
705 # * `prometheus.io/scrape`: Only scrape pods that have a value of `true`
706 # * `prometheus.io/path`: If the metrics path is not `/metrics` override this.
707 # * `prometheus.io/port`: Scrape the pod on the indicated port instead of the default of `9102`.
709 - job_name: "kubernetes-pods"
710 kubernetes_sd_configs:
714 source_labels: [__meta_kubernetes_pod_container_init]
716 - action: keep_if_equal
717 source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_port, __meta_kubernetes_pod_container_port_number]
718 - source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scrape]
721 - source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_path]
723 target_label: __metrics_path__
725 - source_labels: [__address__, __meta_kubernetes_pod_annotation_prometheus_io_port]
727 regex: ([^:]+)(?::\d+)?;(\d+)
729 target_label: __address__
731 regex: __meta_kubernetes_pod_label_(.+)
732 - source_labels: [__meta_kubernetes_namespace]
734 target_label: namespace
735 - source_labels: [__meta_kubernetes_pod_name]
739 # -- Extra scrape configs that will be appended to `server.scrape.config`
740 extraScrapeConfigs: []
741 # - job_name: 'prometheus-blackbox-exporter'
742 # metrics_path: /probe
747 # - https://example.com
749 # - source_labels: [__address__]
750 # target_label: __param_target
751 # - source_labels: [__param_target]
752 # target_label: instance
753 # - target_label: __address__
754 # replacement: prometheus-blackbox-exporter:9115
755# -- Add extra specs dynamically to this chart
757# -- Enterprise license key configuration for VictoriaMetrics enterprise.
758# Required only for VictoriaMetrics enterprise. Check docs [here](https://docs.victoriametrics.com/victoriametrics/enterprise/),
759# for more information, visit [site](https://victoriametrics.com/products/enterprise/).
760# Request a trial license [here](https://victoriametrics.com/products/enterprise/trial/)
761# Supported starting from VictoriaMetrics v1.94.0
765 # -- Use existing secret with license key
767 # -- Existing secret name
769 # -- Key in secret with license key