Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Take variables from enviornment variables #16

Open
Globegitter opened this issue Jun 13, 2017 · 2 comments · May be fixed by #17
Open

Take variables from enviornment variables #16

Globegitter opened this issue Jun 13, 2017 · 2 comments · May be fixed by #17

Comments

@Globegitter
Copy link

It would be great if in addition to a params file or params flag it could also just support environment variables. I think that makes the usage very simple, no flags to remember etc. Also in our current deployment setup we are already passing in these variables via env variables, so it would greatly simplify maintenance if I could just run ktmpl resource.yaml rather than having to mach it to the params flags.

Also running it locally becomes imo a bit simpler, e.g. VARIABLE="test" ktmpl resource.yaml

@jimmycuadra
Copy link
Contributor

Are you imagining that the environment variable form would be the equivalent of the --parameter option? That is, it wouldn't be possible to provide a value through an environment variable and also tell ktmpl not to do any Base64 encoding on it.

@Globegitter
Copy link
Author

Globegitter commented Jun 14, 2017

That is the current implementation yes. I was thinking of some way to tell ktmpl to not do any base64 encoding on the value but also not needing that use-case at the moment. We could add for example a special environment variable KTMPL_BASE64_PARAMETERS=variable,anothervariable and then it does treat those specified parameters as if they would have been passed in with the --base64-parameter flag.

What do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants