mirror of https://github.com/docker/cli.git
man update for docker run with host volumes
Signed-off-by: Mike Brown <brownwm@us.ibm.com> cleaning up docker run -v documentation for man and web reference guide Signed-off-by: Mike Brown <brownwm@us.ibm.com>
This commit is contained in:
parent
f8a62fd1c5
commit
b5a037443d
|
@ -1309,12 +1309,16 @@ container's `/etc/hosts` entry will be automatically updated.
|
|||
|
||||
### VOLUME (shared filesystems)
|
||||
|
||||
-v=[]: Create a bind mount with: [host-dir:]container-dir[:rw|ro].
|
||||
If 'host-dir' is missing, then docker creates a new volume.
|
||||
-v=[]: Create a bind mount with: [host-dir:]container-dir[:<options>], where
|
||||
options are comma delimited and selected from [rw|ro] and [z|Z].
|
||||
If 'host-dir' is missing, then docker creates a new volume.
|
||||
If neither 'rw' or 'ro' is specified then the volume is mounted
|
||||
in read-write mode.
|
||||
--volumes-from="": Mount all volumes from the given container(s)
|
||||
|
||||
> **Note**:
|
||||
> The auto-creation of the host path has been [*deprecated*](/misc/deprecated/#auto-creating-missing-host-paths-for-bind-mounts).
|
||||
|
||||
The volumes commands are complex enough to have their own documentation
|
||||
in section [*Managing data in
|
||||
containers*](/userguide/dockervolumes). A developer can define
|
||||
|
|
|
@ -430,9 +430,17 @@ standard input.
|
|||
""--ulimit""=[]
|
||||
Ulimit options
|
||||
|
||||
**-v**, **--volume**=[]
|
||||
Bind mount a volume (e.g., from the host: -v /host:/container, from Docker: -v /container)
|
||||
|
||||
**-v**, **--volume**=[] Create a bind mount
|
||||
(format: `[host-dir:]container-dir[:<suffix options>]`, where suffix options
|
||||
are comma delimited and selected from [rw|ro] and [z|Z].)
|
||||
|
||||
(e.g., using -v /host-dir:/container-dir, bind mounts /host-dir in the
|
||||
host to /container-dir in the Docker container)
|
||||
|
||||
If 'host-dir' is missing, then docker automatically creates the new volume
|
||||
on the host. **This auto-creation of the host path has been deprecated in
|
||||
Release: v1.9.**
|
||||
|
||||
The **-v** option can be used one or
|
||||
more times to add one or more mounts to a container. These mounts can then be
|
||||
used in other containers using the **--volumes-from** option.
|
||||
|
@ -467,8 +475,6 @@ For example, you can specify either `/foo` or `foo` for a `host-dir` value.
|
|||
If you supply the `/foo` value, Docker creates a bind-mount. If you supply
|
||||
the `foo` specification, Docker creates a named volume.
|
||||
|
||||
**Note:** Multiple Volume options can be added separated by a , (comma).
|
||||
|
||||
**--volumes-from**=[]
|
||||
Mount volumes from the specified container(s)
|
||||
|
||||
|
|
Loading…
Reference in New Issue