mirror of https://github.com/docker/docs.git
Update environment-variables.md
I'm not sure if these are in the right place, but I think it's really important it's somewhere. Closes issue https://github.com/docker/docker.github.io/issues/11286
This commit is contained in:
parent
86613e5e8b
commit
231b04065e
|
@ -18,6 +18,15 @@ web:
|
|||
image: "webapp:${TAG}"
|
||||
```
|
||||
|
||||
If you have multiple environment variables, you can substitute them by providing
|
||||
a path to your environment variables file. By default, the `docker-compose`
|
||||
command will look for a file named `.env` in the directory you run the command.
|
||||
By passing the file as an argument, you can store it anywhere and name it
|
||||
appropriately, e.g (.env.ci, .env.dev, .env.prod). Passing the file path is
|
||||
done using the `--env-file` option:
|
||||
|
||||
``` docker-compose --env-file ./config/.env.dev up ```
|
||||
|
||||
For more information, see the
|
||||
[Variable substitution](compose-file/index.md#variable-substitution) section in the
|
||||
Compose file reference.
|
||||
|
|
Loading…
Reference in New Issue