Support delimited PLUGIN_ENV_FILE


I’m giving a shot to drone CI and still on early stages of doing it, so please advise if there’s a better way of achieving something.

I’m trying to pass some information between multiple steps (docker and kubernetes pipelines), for example building a container with kaniko and using its hash on another step (as I would like deploy ‘immutable’ images). I could get it done by writing into the file passed to PLUGIN_ENV_FILE, as it is something I can mount outside the workspace and have it update as steps proceeds.

Would be nice to support a delimited list of PLUGIN_ENV_FILE to be loaded instead of only one. It is suggested by godotenv/cmd.go at 5c76d3e02c63f90a1bfae60738bbc24ba16f05c4 · joho/godotenv · GitHub and godotenv/godotenv.go at main · joho/godotenv · GitHub

I know it is a bit tricky as plugins are not necessarily under a central entity, but suggesting/supporting this mechanism would be a start.

Although it is a overkill, I’ve wrapped some plugins in a “shell” container with busybox, so at least I can maniplulate files/environment using steps before calling the entrypoint from the original plugin. I’m not suggesting this to upstream, but in case someone lands here with similar issues.