In my imagination, I'd like to have os.getenv call...
# ask-community
b
In my imagination, I'd like to have os.getenv calls at the very top of my flow.py that can pull in private vars in production for credentials and such.
k
If it’s a credential, did you consider using Prefect Secrets instead so that you can just pull it from the Flow?
If you need to pull from
os.get_env()
, then you can pass it through the RunConfg. For example
Copy code
flow.run_confg = DockerRun(...,env={"VARIABLE": "value"})
b
What's the best example of Prefect Secrets you've got?
k
I guess the docs here and here
and this on how to set them