Background

I'm testing some local changes for the Ghost Helm Chart (Primary Chart). However, when cloning that subdirectory and attempting to test the chart, I get an error about its dependency on the MariaDB Helm Chart (Secondary Chart):

Error: found in requirements.yaml, but missing in charts/ directory

For clarity, the two charts will be referred to as Primary/Secondary, in bold, for this short post.

Fix

Option 1

This will pull the dependent charts dynamically.

  1. cd to the root of the chart you're working on from https://github.com/helm/charts. This is based on what's in your chart's requirements.yaml
  2. Then run:
$ helm dependency update

Hang tight while we grab the latest from your chart repositories...
...Unable to get an update from the "local" chart repository (http://127.0.0.1:8879/charts):
	Get http://127.0.0.1:8879/charts/index.yaml: dial tcp 127.0.0.1:8879: connect: connection refused
...Successfully got an update from the "incubator" chart repository
...Successfully got an update from the "stable" chart repository
Update Complete. ⎈Happy Helming!⎈
Saving 2 charts
Downloading mariadb from repo https://kubernetes-charts.storage.googleapis.com/
Downloading redis from repo https://kubernetes-charts.storage.googleapis.com/
Deleting outdated charts

Option 2

This is if you want to manage the dependency on the filesystem manually. Ideally, you wouldn't want to do this.

  1. In the directory of your primary chart, run:
mkdir -p ./charts
  1. Extract the contents of the root directory of Secondary Chart into ./charts.
  2. Now test your Primary Chart to see if the dependency error continues:
helm install --dry-run --name ghost ./

References