'Use local version of an included file in Helm chart
I have created a Helm chart and host it from my organization's private Helm repository. I intend this chart to be used by several different groups in my organization. The chart creates a ConfigMap like this:
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ .Chart.Name }}
data:
config.yaml: |-
{{ .Files.Get "config.yaml" | indent 4}}
The chart looks like:
mychart/
Chart.yaml
values.yaml
config.yaml ** The ConfigMap content **
templates/
That is, the ConfigMap is a YAML file whose content is exactly the content of content.yaml.
The file content.yaml is provided by the chart and is contains several dozen lines. Users of this chart need to be able to substitute their own version of config.yaml for the one that comes with the chart.
Is this possible? If so, how?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
