-
Notifications
You must be signed in to change notification settings - Fork 83
Add ENV VAR FLTYE_ADMIN_ENDPOINT (#4948) #466
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #466 +/- ##
==========================================
- Coverage 67.65% 67.59% -0.06%
==========================================
Files 148 149 +1
Lines 6643 6668 +25
==========================================
+ Hits 4494 4507 +13
- Misses 1859 1868 +9
- Partials 290 293 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Signed-off-by: zychen5186 <[email protected]>
Signed-off-by: zychen5186 <[email protected]>
Signed-off-by: zychen5186 <[email protected]>
Signed-off-by: zychen5186 <[email protected]>
Signed-off-by: zychen5186 <[email protected]>
All fields that show up in cli are also settable through env vars. |
Hi @EngHabu, thanks for pointing this out! I also saw this |
TL;DR
Add support for assigning admin endpoint by passing config via ENV vars
Type
Are all requirements met?
Complete description
I found that the admin endpoint value is assigned by .yaml configure file via viper, however, the viper accessor function is written in flytestdlib and the repo is already set as read-only, so instead I added a function to override the config if env var is set, after
err := configAccessor.UpdateConfig(context.TODO())
in root.go. Also, further need for customized env var could be added in this function as well.for testing, please set the ENV var $FLTYE_ADMIN_ENDPOINT to the desired url, if ENV var is set, it would be used as the endpoint of admin instead the one specified in the config yaml file. e.g.
export FLTYE_ADMIN_ENDPOINT=localhost:30080
Tracking Issue
flyteorg/flyte#4948
Follow-up issue
NA