- 
                Notifications
    You must be signed in to change notification settings 
- Fork 558
Description
I want to use .Files.Get and .Files.Glob just like I can in the Helm Chart. I want to define the Helmfile release along with a license file and configuration files needed by the release. I will define many releases and the configuration files for each have a lot in common and so I want to define the common chunks in fragment files and include those fragments in many configuration files.
To accomplish this, in my Helmfile release's values template, I want to do the following:
licenseData: {{ .Files.Get "license.bin" | b64enc }}
configData:
  {{ (tpl (.Files.Glob "config/*").AsConfig . ) | indent 2 }}The Helm Chart defines a ConfigMap that has:
binaryData:
  license.bin: {{ .Values.licenseData }}
data:
  {{ toYaml .Values.configData | indent 2 }}Then the ConfigMap is mounted into a container. The result is that the license file and configuration files specified by the Helmfile values template are available in the running container. Notice that the Helmfile's values template uses the "tpl" function as a way to process the config files as templates just like I can in a Helm Chart. This allows the config file to include common configuration fragments.
I could use the readFile function in place of .Files.Get, but it is nice if the Helmfile syntax is the same as the Helm Chart syntax. This is similar to existing issues #724 and #414 .