helmfile "chart ... not found" (needs helm repo add) in CI
A release points at a chart like bitnami/nginx, but the bitnami repository is not registered or its index is stale in CI, so helm reports the chart cannot be found. helmfile normally runs the repo add for you if repositories: is declared.
What this error means
helmfile sync or apply fails with "Error: chart \"bitnami/nginx\" not found" or "no chart name found", usually on the first CI run before repos are cached.
Error: chart "bitnami/nginx" version "" not found in repository cache
in ./helmfile.yaml: command "helm" exited with non-zero statusCommon causes
The repository is not declared or not added
The repositories: block is missing the repo, so helm has no index entry mapping the alias to a URL.
The repo cache is empty on a fresh runner
A clean CI runner has no ~/.cache/helm/repository entries, so the chart index must be fetched before the chart resolves.
How to fix it
Declare repositories and let helmfile sync them
- Add the chart repo under
repositories:in helmfile.yaml. - Run
helmfile repos(ordeps) so helmfile adds and updates the repo before apply. - Reference the chart as
alias/chartmatching the declared name.
repositories:
- name: bitnami
url: https://charts.bitnami.com/bitnami
releases:
- name: web
chart: bitnami/nginxAdd and update the repo manually before helmfile
If you drive helm directly, add the repo and refresh its index in a setup step.
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update
helmfile applyHow to prevent it
- Declare every chart repo in
repositories:so helmfile can add them. - Run
helmfile reposearly in CI to populate the cache. - Cache
~/.cache/helmbetween runs to avoid re-fetching indexes.