thanos
by Bitnami
Thanos is a highly available metrics system that can be added on top of existing Prometheus deployments, providing a global query view across all Prometheus installations.
About this chart
Bitnami package for Thanos
Thanos is a highly available metrics system that can be added on top of existing Prometheus deployments, providing a global query view across all Prometheus installations.
Trademarks: This software listing is packaged by Bitnami. The respective trademarks mentioned in the offering are owned by the respective companies, and use of them does not imply any affiliation or endorsement.
TL;DR
helm install my-release oci://registry-1.docker.io/bitnamicharts/thanos
Looking to use Thanos in production? Try VMware Tanzu Application Catalog, the commercial edition of the Bitnami catalog.
⚠️ Important Notice: Upcoming changes to the Bitnami Catalog
Beginning August 28th, 2025, Bitnami will evolve its public catalog to offer a curated set of hardened, security-focused images under the new Bitnami Secure Images initiative. As part of this transition:
- Granting community users access for the first time to security-optimized versions of popular container images.
- Bitnami will begin deprecating support for non-hardened, Debian-based software images in its free tier and will gradually remove non-latest tags from the public catalog. As a result, community users will have access to a reduced number of hardened images. These images are published only under the “latest” tag and are intended for development purposes
- Starting August 28th, over two weeks, all existing container images, including older or versioned tags (e.g., 2.50.0, 10.6), will be migrated from the public catalog (docker.io/bitnami) to the “Bitnami Legacy” repository (docker.io/bitnamilegacy), where they will no longer receive updates.
- For production workloads and long-term support, users are encouraged to adopt Bitnami Secure Images, which include hardened containers, smaller attack surfaces, CVE transparency (via VEX/KEV), SBOMs, and enterprise support.
These changes aim to improve the security posture of all Bitnami users by promoting best practices for software supply chain integrity and up-to-date deployments. For more details, visit the Bitnami Secure Images announcement.
Introduction
This chart bootstraps a Thanos deployment on a Kubernetes cluster using the Helm package manager.
Prerequisites
- Kubernetes 1.23+
- Helm 3.8.0+
- PV provisioner support in the underlying infrastructure
Installing the Chart
To install the chart with the release name my-release:
helm install my-release oci://REGISTRY_NAME/REPOSITORY_NAME/thanos
Note: You need to substitute the placeholders
REGISTRY_NAMEandREPOSITORY_NAMEwith a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to useREGISTRY_NAME=registry-1.docker.ioandREPOSITORY_NAME=bitnamicharts.
These commands deploy Thanos on the Kubernetes cluster with the default configuration. The configuration section lists the parameters that can be configured during installation.
Tip: List all releases using
helm list
Architecture
This charts allows you install several Thanos components, so you deploy an architecture as the one below:
+--------------+ +--------------+ +--------------+
| Thanos |----------------> | Thanos Store | | Thanos |
| Query | | | Gateway | | Compactor |
+--------------+ | +--------------+ +--------------+
push | | |
+--------------+ alerts +--------------+ | | storages | Downsample &
| Alertmanager | <----------| Thanos | <----| | query metrics | compact blocks
| (*) | | Ruler | | | |
+--------------+ +--------------+ | \/ |
^ | | +----------------+ |
| push alerts +--------------|----> | MinIO® (*) | <---------+
| | | |
+------------------------------+ | +----------------+
|+------------+ +------------+| | ^
|| Prometheus |->| Thanos || <----------------+ |
|| (*) |<-| Sidecar (*)|| query | inspect
|+------------+ +------------+| metrics | blocks
+------------------------------+ |
+--------------+
| Thanos |
| Bucket Web |
+--------------+
Note: Components marked with (*) are provided by subchart(s) (such as the Bitnami MinIO® chart) or external charts (such as the Bitnami kube-prometheus chart).
Check the section Integrate Thanos with Prometheus and Alertmanager for detailed instructions to deploy this architecture.
Configuration and installation details
Resource requests and limits
Bitnami charts allow setting resource requests and limits for all containers inside the chart deployment. These are inside the resources value (check parameter table). Setting requests is essential for production workloads and these should be adapted to your specific use case.
To make this process easier, the chart contains the resourcesPreset values, which automatically sets the resources section according to different presets. Check these presets in the bitnami/common chart. However, in production workloads using resourcesPreset is discouraged as it may not fully adapt to your specific needs. Find more information on container resource management in the official Kubernetes documentation.
Prometheus metrics
This chart can be integrated with Prometheus by setting metrics.enabled to true. This will expose Thanos native Prometheus endpoint in the service. It will have the necessary annotations to be automatically scraped by Prometheus.
Prometheus requirements
It is necessary to have a working installation of Prometheus or Prometheus Operator for the integration to work. Install the Bitnami Prometheus helm chart or the Bitnami Kube Prometheus helm chart to easily have a working Prometheus in your cluster.
Integration with Prometheus Operator
The chart can deploy ServiceMonitor objects for integration with Prometheus Operator installations. To do so, set the value metrics.serviceMonitor.enabled=true. Ensure that the Prometheus Operator CustomResourceDefinitions are installed in the cluster or it will fail with the following error:
no matches for kind "ServiceMonitor" in version "monitoring.coreos.com/v1"
Install the Bitnami Kube Prometheus helm chart for having the necessary CRDs and the Prometheus Operator.
Securing traffic using TLS
Thanos can encrypt communications by setting *.tls.enabled=true (under the query.grpc.client, query.grpc.server, storegateway.grpc.server and receive.grpc.server sections) value. The chart allows three configuration options:
- Provide the content of the certificates using the
*.tls.ca,*.tls.cert,*.tls.key(under thequery.grpc.client,query.grpc.server,storegateway.grpc.serverandreceive.grpc.serversections) values. - Provide your own secrets using the
*.tls.existingSecret(under thequery.grpc.client,query.grpc.server,storegateway.grpc.serverandreceive.grpc.serversections) values. Apart from providing the secret name also set a key mapping to theca-cert,tls-certandtls-keyelements. For example:
receive:
grpc:
server:
tls:
existingSecret:
name: foo
keyMapping:
ca-cert: ca.pem
tls-cert: cert.pem
tls-key: key.pem
- Have the chart auto-generate the certificates using
*.tls.autoGenerated=true(under thequery.grpc.client,query.grpc.server,storegateway.grpc.serverandreceive.grpc.serversections).
Rolling VS Immutable tags
It is strongly recommended to use immutable tags in a production environment. This ensures your deployment does not change automatically if the same tag is updated with a different image.
Bitnami will release a new chart updating its containers if a new version of the main container, significant changes, or critical vulnerabilities exist.
Adding extra flags
In case you want to add extra flags to any Thanos component, you can use XXX.extraFlags parameter(s), where XXX is placeholder you need to replace with the actual component(s). For instance, to add extra flags to Thanos Store Gateway, use:
storegateway:
extraFlags:
- --sync-block-duration=3m
- --chunk-pool-size=2GB
This also works for multi-line flags. This can be useful when you want to configure caching for a particular component without using a configMap. For example, to configure the query-range response cache of the Thanos Query Frontend, use:
queryFrontend:
extraFlags:
- |
--query-range.response-cache-config=
type: MEMCACHED
config:
addresses:
- <MEMCACHED_SERVER>:11211
timeout: 500ms
max_idle_connections: 100
max_async_concurrency: 10
max_async_buffer_size: 10000
max_get_multi_concurrency: 100
max_get_multi_batch_size: 0
dns_provider_update_interval: 10s
expiration: 24h
Using custom Objstore configuration
This helm chart supports using custom Objstore configuration.
You can specify the Objstore configuration using the objstoreConfig parameter.
In addition, you can also set an external Secret with the configuration file. This is done by setting the existingObjstoreSecret parameter. Note that this will override the previous option. If needed you can also provide a custom Secret Key with existingObjstoreSecretItems, please be aware that the Path of your Secret should be objstore.yml.
Using custom Query Service Discovery configuration
This helm chart supports using custom Service Discovery configuration for Query.
You can specify the Service Discovery configuration using the query.sdConfig parameter.
In addition, you can also set an external ConfigMap with the Service Discovery configuration file. This is done by setting the query.existingSDConfigmap parameter. Note that this will override the previous option.
Using custom Ruler configuration
This helm chart supports using custom Ruler configuration.
You can specify the Ruler configuration using the ruler.config parameter.
In addition, you can also set an external ConfigMap with the configuration file. This is done by setting the ruler.existingConfigmap parameter. Note that this will override the previous option.
Running Thanos with HTTPS and basic authentication
This helm charts supports using HTTPS and basic authentication. The underlying feature is experimental and might change in the future, so are the associated settings in the chart. For more information, please refer to Thanos documentation.
This feature can be enabled by using the following values:
-
https.enabled=true. Enabling HTTPS requires the user to provide the TLS certificate and Key for Thanos, which can be done using one of the following options:- Provide a secret using
https.existingSecret. The secret must contain the keystls.crtortls.key(key names can be renamed using the valueshttps.keyFilenameandhttps.certFilename). - Provide the certificate and key in your values.yaml under the values
https.certandhttps.key. - Use
https.autoGenerated=true, using this value Helm will generate a self-signed key pair during the chart initialization. Not recommended for production environments.
- Provide a secret using
-
auth.basicAuthUsers.*. An dictionary of key / values, where the keys corresponds to the users that will have access to Thanos and the values are the plaintext passwords. Passwords will be later encrypted with bcrypt. -
Alternatively, provide your own Thanos http config file using the value
httpConfigorexistingHttpConfigSecret. This may cause any settings underhttps.*orauth.*to be ignored, except for the settings related to the TLS certificates. When providing a configuration file using these parameters, the chart Probes w
Deploy thanos with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has thanos on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.
- Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
- Place the chartthanos is pinned at v17.3.1 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
- ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below opentenant validate opentenant.yaml terraform init && terraform apply