Helmfile Declarative Helm releases
Light · Postcard
102 × 152 mm · PDF
Dark · Postcard
102 × 152 mm · PDF
Ink saver · Postcard
102 × 152 mm · PDF
Light · A4 landscape
297 × 210 mm · PDF
Dark · A4 landscape
297 × 210 mm · PDF
Ink saver · A4 landscape
297 × 210 mm · PDF
Light · A3 landscape
420 × 297 mm · PDF
Dark · A3 landscape
420 × 297 mm · PDF
Ink saver · A3 landscape
420 × 297 mm · PDF
Start here
helmfile inithelmfile reposhelmfile diffhelmfile applyhelmfile synchelmfile -e <env> apply
helmfile -l <key>=<val> apply
helmfile destroy
Concepts
- helmfile.yaml desired state
- Helm releases charts + values
- Cluster kube-context
Project
helmfile inithelmfile create <name>
helmfile version
helmfile reposhelmfile depshelmfile listhelmfile list --output json
helmfile show-dag
helmfile linthelmfile completion <shell>
Deploy
helmfile diffhelmfile applyhelmfile apply -i
helmfile synchelmfile sync --wait --timeout <sec>
helmfile diff --skip-diff-on-install
helmfile template
helmfile destroy
helmfile statushelmfile testhelmfile write-values
helmfile fetch --output-dir <dir>
helmfile apply --skip-deps
Targeting
helmfile -f <file or dir> <cmd>
helmfile -e <env> <cmd>
helmfile -l name=<release> <cmd>
helmfile -l
<key>=<val>,<key2>=<val2>
<cmd>
helmfile -l <k>=<a> -l <k>=<b>
<cmd>
helmfile -l <key>!=<val> <cmd>
helmfile -l namespace=<ns> <cmd>
helmfile -l chart=<chart> <cmd>
helmfile -l dir=<path> <cmd>
helmfile --allow-no-matching-release <cmd>
helmfile -n <ns> <cmd>
helmfile --kube-context <ctx> <cmd>
helmfile --kubeconfig <file> <cmd>
State values & output
helmfile --state-values-set <key>=<val>
<cmd>
helmfile --state-values-file <file> <cmd>
helmfile print-env
helmfile buildhelmfile --debug <cmd>
helmfile -q <cmd>
helmfile --no-color <cmd>
helmfile -f - <cmd>
helmfile -b <path> <cmd>
helmfile cache cleanup
helmfile.yaml
repositories: - name: bitnami url: https://charts.bitnami.com/bitnami---releases: - name: cache namespace: data chart: bitnami/redis version: <x.y.z> values: - values/redis.yaml
environments: default: values: [env/default.yaml] production: values: [env/production.yaml]---# in releases: installed: {{ eq .Environment.Name "production" | toYaml }}
helmDefaults: wait: true timeout: 600 createNamespace: true historyMax: 10
releases: - name: app chart: ./charts/app needs: [data/cache] condition: app.enabled labels: {tier: web}
hooks: - events: ["presync"] showlogs: true command: ./check.sh - events: ["postsync"] kubectlApply: {filename: extra.yaml}
bases: - environments.yamlhelmfiles: - path: apps/*/helmfile.yaml missingFileHandler: Warn
| Event | Runs |
|---|---|
prepare |
after a release is loaded |
presync |
before install or upgrade |
postsync |
after install or upgrade |
preuninstall |
before uninstall |
postuninstall |
after uninstall |
cleanup |
after each release |
Recipes
helmfile -e staging diffhelmfile -e staging apply -i
helmfile -e production -l name=<release> diffhelmfile -e production -l name=<release> apply
helmfile -e <env> template > out.yamlhelmfile -e <env> buildhelmfile show-dag
helmfile create <name>cd <name> && helmfile inithelmfile repos && helmfile diff



