Helmfile — Declarative Helm Chart Deployment Manager
A declarative spec for deploying multiple Helm charts as a single unit, enabling environment-specific overrides, dependency ordering, and diff-based previews before apply.
What it is
Helmfile is a declarative tool for managing multiple Helm chart deployments. Instead of running individual helm install and helm upgrade commands, you define all your releases in a single helmfile.yaml and deploy them together. Helmfile handles repository management, dependency ordering, environment-specific value overrides, and diff-based previews before applying changes.
Helmfile targets DevOps and platform engineers who manage Kubernetes clusters with many Helm releases. If you run more than a few Helm charts and need consistent, repeatable deployments across environments, Helmfile provides the orchestration layer.
How it saves time or tokens
Managing Helm releases individually means tracking versions, values files, and upgrade order manually. Helmfile centralizes this into a single file that describes the desired state. Running helmfile apply computes the diff between the current cluster state and the desired state, then applies only the changes.
Environment-specific overrides (environments: block) eliminate the need for separate values files per environment. You define base values once and override specific settings for staging, production, or other environments.
How to use
- Install Helmfile:
brew install helmfile
- Create a
helmfile.yaml:
repositories:
- name: prometheus
url: https://prometheus-community.github.io/helm-charts
releases:
- name: prometheus
namespace: monitoring
chart: prometheus/prometheus
version: 25.0.0
values:
- values/prometheus.yaml
- Deploy:
helmfile apply
Example
environments:
staging:
values:
- env/staging.yaml
production:
values:
- env/production.yaml
repositories:
- name: ingress-nginx
url: https://kubernetes.github.io/ingress-nginx
- name: cert-manager
url: https://charts.jetstack.io
releases:
- name: cert-manager
namespace: cert-manager
chart: cert-manager/cert-manager
version: 1.14.0
set:
- name: installCRDs
value: true
- name: ingress-nginx
namespace: ingress
chart: ingress-nginx/ingress-nginx
version: 4.9.0
needs:
- cert-manager/cert-manager
This deploys cert-manager first (because ingress-nginx depends on it), with environment-specific value overrides for staging and production.
Related on TokRepo
- DevOps tools -- Explore other Kubernetes and infrastructure tools
- Automation tools -- Browse deployment automation solutions
Common pitfalls
- Helmfile requires Helm and the helm-diff plugin. Install both before running helmfile:
helm plugin install https://github.com/databus23/helm-diff. Missing helm-diff causeshelmfile diffto fail silently. - The
needs:directive defines deployment order. Without it, Helmfile deploys releases in parallel, which can fail if one release depends on CRDs or resources from another. - Helmfile caches Helm repositories locally. Stale caches can cause version resolution failures. Run
helmfile reposto update repository indexes before deploying.
Frequently Asked Questions
Helmfile is a CLI tool for imperative deployments -- you run helmfile apply to deploy. ArgoCD is a GitOps controller that continuously reconciles cluster state with a Git repository. They can be used together: commit helmfile.yaml to Git and let ArgoCD apply it.
Yes. Helmfile supports multiple kubeconfig contexts. You can define releases targeting different clusters in the same helmfile.yaml using the kubeContext field. This enables managing multi-cluster deployments from a single configuration.
Yes. Helm hooks defined in chart templates work normally with Helmfile. Helmfile does not interfere with Helm's hook mechanism. You can also use Helmfile's own hooks for pre/post-apply operations.
Yes. Helmfile supports Go templating in helmfile.yaml. You can use environment variables, template functions, and conditional logic. The environments block provides typed values that are accessible via template expressions.
Use helmfile --selector name=release-name rollback to roll back a specific release. For all releases, use helmfile rollback. Helmfile delegates to Helm's rollback mechanism, which reverts to the previous release revision.
Citations (3)
- Helmfile GitHub— Helmfile is a declarative spec for Helm chart deployments
- Helmfile Documentation— Environment overrides and dependency ordering
- Helm Diff Plugin— Helm diff plugin for preview
Related on TokRepo
Discussion
Related Assets
WCDB — WeChat Cross-Platform Database Framework
A high-performance, cross-platform database framework developed by WeChat, built on SQLite with ORM, encryption, repair, and migration capabilities.
sql.js — Run SQLite in the Browser with WebAssembly
A JavaScript library that compiles SQLite to WebAssembly, letting you run a full SQL database entirely in the browser or Node.js.
Realm — High-Performance Mobile Database
A fast, object-oriented mobile database designed as a modern replacement for SQLite and Core Data on iOS and Android.