Merge pull request #1180 from sherbondy/patch-1
Update docker-options.md
This commit is contained in:
commit
0816ee7575
1 file changed
+9
-9
@@ -19,40 +19,40 @@ Add some options
|
|||||||
```bash
|
```bash
|
||||||
$ dokku docker-options:add myapp deploy "-v /host/path:/container/path"
|
$ dokku docker-options:add myapp deploy "-v /host/path:/container/path"
|
||||||
$ dokku docker-options:add myapp run "-v /another/container/path"
|
$ dokku docker-options:add myapp run "-v /another/container/path"
|
||||||
$ dokku docker-options:add myapp "-link container_name:alias"
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Check what we added
|
Check what we added
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ dokku docker-options myapp
|
$ dokku docker-options myapp
|
||||||
-link container_name:alias
|
Run options:
|
||||||
-v /host/path:/container/path
|
--link container_name:alias
|
||||||
-v /another/container/path
|
-v /host/path:/container/path
|
||||||
|
-v /another/container/path
|
||||||
```
|
```
|
||||||
|
|
||||||
Remove an option
|
Remove an option
|
||||||
```bash
|
```bash
|
||||||
$ dokku docker-options:remove myapp "-link container_name:alias"
|
$ dokku docker-options:remove myapp run "--link container_name:alias"
|
||||||
```
|
```
|
||||||
|
|
||||||
Advanced Usage (avoid if possible)
|
Advanced Usage (avoid if possible)
|
||||||
------------
|
------------
|
||||||
|
|
||||||
In your applications folder (/home/dokku/app_name) create a file called DOCKER_OPTIONS.
|
In your applications folder (/home/dokku/app_name) create a file called DOCKER_OPTIONS_RUN (or DOCKER_OPTIONS_BUILD or DOCKER_OPTIONS_DEPLOY).
|
||||||
|
|
||||||
Inside this file list one docker option per line. For example:
|
Inside this file list one docker option per line. For example:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
-link container_name:alias
|
--link container_name:alias
|
||||||
-v /host/path:/container/path
|
-v /host/path:/container/path
|
||||||
-v /another/container/path
|
-v /another/container/path
|
||||||
```
|
```
|
||||||
|
|
||||||
The above example will result in the following options being passed to docker during deploy and docker run:
|
The above example will result in the following options being passed to docker during docker run:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
-link container_name:alias -v /host/path:/container/path -v /another/container/path
|
--link container_name:alias -v /host/path:/container/path -v /another/container/path
|
||||||
```
|
```
|
||||||
|
|
||||||
You may also include comments (lines beginning with a #) and blank lines in the DOCKER_OPTIONS file.
|
You may also include comments (lines beginning with a #) and blank lines in the DOCKER_OPTIONS file.
|
||||||
|
|||||||
Reference in new issue
Block a user