esc icon indicating copy to clipboard operation
esc copied to clipboard

Add a dotenv function to format configuration for environment files

Open lblackstone opened this issue 9 months ago • 0 comments

Hello!

  • Vote on this issue by adding a 👍 reaction
  • If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)

Issue details

From @pgavlin:

It'd be nice if there was a function like fn::dotenv that took an object and returned a dotenv-formatted string

We can write the following today:

values:
  files:
    DOCKER_ENVFILE: |
      FOO=bar

This would be more flexible as structured configuration along these lines, which would generate an equivalent environment:

values:
  dockerEnv:
    FOO: bar
  files:
    DOCKER_ENVFILE: { fn::dotenv: "${dockerEnv}" }

Affected area/feature

lblackstone avatar May 08 '24 00:05 lblackstone