0

Right now my application repos have directories that look like this:

myapp
  code/
  myappChartConfig/
    myappChart/
    dev.yaml
    prod.yaml

The chart is in myappChart/ and my dev/prod settings are outside it in dev/prod yaml files. On deploy if it's dev or prod, the right config is supplied with -f.

I want instead to include my dev/prod YAML files inside the chart itself. So when I push the chart to a repo it includes the configs and when I pull it down I get the chart and its configs.

Does Helm support this? This is not the helmignore use case. I want to include these files in the chart but I don't want helm to process them as though they are manifests- they are values files (but not the default values.yaml file, env specific ones).

What I want to avoid is something wonky like naming the files dev.yaml.deploy and then have scripts pull down the chart and move and rename those files before running helm upgrade. It would be nice to refer to them with -f and have them be inside the chart's folder when it's pulled down.

halfer
  • 19,824
  • 17
  • 99
  • 186
red888
  • 27,709
  • 55
  • 204
  • 392
  • Silly question but did you try moving them into the chart repo and just calling `-f myappChart/dev.yaml` when you did what happened? – Josh Beauregard Nov 10 '21 at 16:29
  • Reminder: please run your questions through a spell-checker. Your stylistic aversion to apostrophes is creating a disproportionate amount of editing work. Take this as a plea from editors - have mercy on us! – halfer Nov 10 '21 at 21:31

1 Answers1

0

You can split it into 2 charts.

Chart named prod includes a values.yaml file containing the configuration values of prod.

Chart named dev includes a values.yaml file containing the configuration values of dev.

Hope it's useful for you!

quoc9x
  • 1,423
  • 2
  • 9
  • 26