I'm working on an umbrella chart which has several child charts. On the top level, I have a file values-ext.yaml which contains some values which are used in the child charts.
sql:
common:
host: <SQL Server host>
user: <SQL user>
pwd: <SQL password>
These settings are read in configmap.yaml of a child chart. In this case, a SQL Server connection string is built up from these settings.
apiVersion: v1
kind: ConfigMap
metadata:
name: "childchart-config"
labels:
app: some-app
chart: my-child-chart
data:
ConnectionStrings__DbConnection: Server={{ .Values.sql.common.host }};Database=some-db
I test the chart from the umbrella chart dir like this: helm template --values values-ext.yaml .
It gives me this error:
executing "my-project/charts/child-chart/templates/configmap.yaml" at <.Values.sql.common.host>:
nil pointer evaluating interface {}.host
So, it clearly can't find the values that I want to read from the values-ext.yaml file.
I should be able to pass in additional values files like this, right?
I also tried with $.Values.sql.common.host but it doesn't seem to matter.
What's wrong here?