#Secret from env

1 messages · Page 1 of 1 (latest)

shut drum
#

If you’re using modules you don’t have direct access to your host’s env variables. You need to get the secret as an argument to the function and set it from the CLI.

viral coral
#

interesting, even when it is just a python script os.environ.get is not able to load them? there is some how env cleanup on dagger startup?

shut drum
viral coral
#

Got it. Thanks. Now the question there is any way to tell dagger to read host env vars on call? Use case: have 10 diff en vars defined in GHA to be use through the pipeline. Run dagger with 10+ --var flags it's really long

silk knoll
#

Currently no, you pass all 10+ in as arguments. There's plans in the works or in progress to improve the DX on that though