-
Notifications
You must be signed in to change notification settings - Fork 80
Defining environment variables #208
Comments
On the github page for geard they have an example: "$ gear install ccoleman/envtest localhost/env-test1 --env-file=deployment/fixtures/simple.env Loading environment into a running container is dependent on the "docker run --env-file" option in Docker master from 0.9.x after April 1st. You must start the daemon with "gear daemon --has-env-file" in order to use the option - this option will be made the default after 0.9.1 lands and the minimal requirements will be updated." One example of an .env file can be found in the repo itself: |
You can also set env via
|
Thanks for the notes. I had tried --env-file but I must have been doing something wrong. Is there a way to define environment variables via the json definition of containers? |
[edit] I'm an idiot, I missed the note about starting the gear daemon with --has-env-file Thanks all! |
bluepojo the default has now been changed to be "true" (but it's not in the Fedora packages yet I don't think) since Docker landed their env file support. |
I suspect this is me being new to working with gear, but I cannot figure out how to provide environment variables to my containers.
What is the correct way of setting environment variables, equivalent to
-e
fromdocker run
?The text was updated successfully, but these errors were encountered: