-
Notifications
You must be signed in to change notification settings - Fork 75
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
Env Variable substitution in config.yml #96
Comments
You can use the JS config files to use env variables. If you like to have the config in YAML then you can import the config in js config file and change what you need and use the JS config with kongfig. |
@CyExy could we avoid the use of JS config file and do ENV variable substitution directly on YAML file? |
I can see how this would be useful. How would this look: apis:
- name: test
ensure: present
attributes:
upstream_url: 'http://%env(HOST)%'
hosts:
- '%env(HOST)%' So apis:
- name: test
ensure: present
attributes:
upstream_url: 'http://mockbin.com'
hosts:
- 'mockbin.com' |
Looks good. And what do you think about this?
This way it would be more similar to Compose variables substitution. |
That could work, although compose and JS template literals are both using curly braces so maybe |
Hi @CyExy , is there some news about this feature? |
Hello everyone,
kongfig is very cool, saved us tons of time, thank you. Is there a way to use env variable substitution from env variable in config.yml file?
The text was updated successfully, but these errors were encountered: