Comments (3)
Interesting. We typically only use .env files for configuration show we haven't come across this issue. Under the hood we just use starlette config, which does read from the envvars but perhaps not in this context?
https://www.starlette.io/config/
from dispatch.
When dispatch is brought up via docker-compose, .env
environment file is parsed by docker-compose
https://github.com/Netflix/dispatch-docker/blob/master/docker-compose.yml#L24
then those variables are given to each docker container as environment variables.
Those environment variables are stored in config.environ
https://github.com/encode/starlette/blob/master/starlette/config.py#L55
while .env file parsed by dispatch (or its underlying starlette) are stored in config.file_values
.
You use only latter one, so show_config()
is implemented to support that case only.
But that's not the main point. Regardless how .env
contents are given to dispatch, my feature request is to show parsed config, not to show what are given.
One of typical use case is to detect typo in variable name. If I made a typo in variable name but it has default value (or, the variable is referenced by config(..., default=...)
), I expect to see the default value on show_config()
, so that I could find that there are some problems in config. Current code displays just the typo as-is, then I'll observe unexpected behavior, then I'm supposed to dig deeper to see if it's bug of program or misconfiguration of program.
from dispatch.
I've put together #264... I think it's kind of hacky but it's not terrible. Please let me know if that satisfies your use case.
from dispatch.
Related Issues (20)
- getting duplicate key value slug key error while rebuiling image HOT 6
- slack commonds are not working HOT 7
- can we get notification for the tasks creation ? HOT 2
- How to upgrade dispatch ? HOT 3
- docker file link syntax issue in new version HOT 1
- Support dynamic enums for Case Status and Resolution HOT 4
- API auth when SSO is enabled using PKCE HOT 7
- Implementing signal-consumer for signals ingestion HOT 2
- Create incident from slack fails if "Type" not provided HOT 3
- Organization resets to default and project to blank HOT 2
- Zoom plugin does not work anymore HOT 3
- SMTP Mail Configuration for Notification channels HOT 2
- v-alert icon colors don't match text HOT 3
- How to delete all incidents at once ? HOT 3
- Support for microsoft teams for docs and communication HOT 2
- Configure GSuite integration without domain wide delegation? HOT 2
- cannot import name 'createdb' from 'sh' HOT 2
- Slack event hook returns invalid response HOT 5
- Why does dispatch run using qemu emulator? HOT 3
- Multiple accounts be made with same email HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dispatch.