I consider using the helm structure with common chart, chart per service using it, and umbrella chart. Like in this example. But then I create values-local.yaml
values-stage.yaml
and values-prod.yaml
for each service.
And if I run charts separately, I can pass helm install -f values-prod.yaml
, but when I run my umbrella chart how do I make all it's subcharts use values-prod.yaml
from their repos?
So if your directory structure looks like this:
├── umbrela_chart
│ ├── charts
│ │ ├── chart1
│ │ ├── chart2
│ │── values
│ │ ├── values-prod.yaml
│ │ values.yaml
and your values-prod.yaml config for the umbrela_chart looks like:
chart1:
chart1_key:
chart1_sub_key: value1
chart2:
chart1_key:
chart1_sub_key: value1
then when you deploy your umbrela_chart the sub-charts would automatically use the values defined in values-prod.yaml. So the important step is to define all the values for the chart "chart1" under the key "chart1" and the same for the other charts.