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

Environment variable support? #80

Closed
stephenmuss opened this issue Apr 28, 2015 · 6 comments
Closed

Environment variable support? #80

stephenmuss opened this issue Apr 28, 2015 · 6 comments

Comments

@stephenmuss
Copy link

Environment variable support could be quite useful.

See Mozilla's Heka for an example of how it could work.

Is this something you would consider?

@BurntSushi
Copy link
Owner

Unlikely. Thus far, I've kept pretty strict compliance with the spec and I'd like to continue that. That means it will probably be up to the application to implement on top of TOML. Perhaps there is a reusable component that could be extracted from Heka and put into a separate library?

@stephenmuss
Copy link
Author

I did have a quick look at their source but maybe I'll go back and take another. Thanks for your input.

@dodwyer
Copy link

dodwyer commented May 6, 2015

This seems to be the commit in question: chancez/heka@6ed5cb4
I'm reviewing this so we can enable env variables in confd TOML files as discussed here: kelseyhightower/confd#131

@supershal
Copy link

+1 for Environment variable support in toml parser.
We need to inject values from environment variable easily specially when we are trying to run an application as docker container in a isolated environment.
Yes, we can write custom code on top of toml to inject env variable values in the file or override them code itself.
However it become difficult when you want to dockerize third party applications without modifying it's source code or deployment mechanism. We can't use them as it is in container environments.
I would love to have this implemented in the parser itself as a convention so that it can be used by all applications.

@BurntSushi if you strongly believe this requirement should be in toml spec, then we should ask community to add it to the spec.

@cespare
Copy link
Collaborator

cespare commented Feb 22, 2016

I don't see why a toml library (or the spec) ought to know about environment variables. That seems like a concern for the systems which use toml.

@cespare cespare closed this as completed Feb 22, 2016
@o3o3o
Copy link

o3o3o commented Sep 23, 2016

👍 for Environment variable support in toml parser.
We use confd in docker container, the env is defined in Dockerfile, so I think it will be useful for the env variable support in toml.

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

No branches or pull requests

6 participants