1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Fix some flaws in docs

Signed-off-by: Jian Zhang <zhangjian.fnst@cn.fujitsu.com>
This commit is contained in:
Jian Zhang 2016-02-17 11:54:45 +08:00
parent bebad9e5c1
commit cdc7f26715
7 changed files with 17 additions and 17 deletions

View file

@ -31,7 +31,7 @@ volumes mounted inside the container.
By default, the container being committed and its processes will be paused By default, the container being committed and its processes will be paused
while the image is committed. This reduces the likelihood of encountering data while the image is committed. This reduces the likelihood of encountering data
corruption during the process of creating the commit. If this behavior is corruption during the process of creating the commit. If this behavior is
undesired, set the 'p' option to false. undesired, set the `--pause` option to false.
The `--change` option will apply `Dockerfile` instructions to the image that is The `--change` option will apply `Dockerfile` instructions to the image that is
created. Supported `Dockerfile` instructions: created. Supported `Dockerfile` instructions:

View file

@ -23,7 +23,7 @@ You can copy from the container's file system to the local machine or the
reverse, from the local filesystem to the container. If `-` is specified for reverse, from the local filesystem to the container. If `-` is specified for
either the `SRC_PATH` or `DEST_PATH`, you can also stream a tar archive from either the `SRC_PATH` or `DEST_PATH`, you can also stream a tar archive from
`STDIN` or to `STDOUT`. The `CONTAINER` can be a running or stopped container. `STDIN` or to `STDOUT`. The `CONTAINER` can be a running or stopped container.
The `SRC_PATH` or `DEST_PATH` be a file or directory. The `SRC_PATH` or `DEST_PATH` can be a file or directory.
The `docker cp` command assumes container paths are relative to the container's The `docker cp` command assumes container paths are relative to the container's
`/` (root) directory. This means supplying the initial forward slash is optional; `/` (root) directory. This means supplying the initial forward slash is optional;
@ -85,4 +85,4 @@ It is not possible to copy certain system files such as resources under
Using `-` as the `SRC_PATH` streams the contents of `STDIN` as a tar archive. Using `-` as the `SRC_PATH` streams the contents of `STDIN` as a tar archive.
The command extracts the content of the tar to the `DEST_PATH` in container's The command extracts the content of the tar to the `DEST_PATH` in container's
filesystem. In this case, `DEST_PATH` must specify a directory. Using `-` as filesystem. In this case, `DEST_PATH` must specify a directory. Using `-` as
`DEST_PATH` streams the contents of the resource as a tar archive to `STDOUT`. the `DEST_PATH` streams the contents of the resource as a tar archive to `STDOUT`.

View file

@ -37,7 +37,7 @@ Docker networks report the following events:
The `--since` and `--until` parameters can be Unix timestamps, date formatted The `--since` and `--until` parameters can be Unix timestamps, date formatted
timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed
relative to the client machines time. If you do not provide the --since option, relative to the client machines time. If you do not provide the `--since` option,
the command returns only new and/or live events. Supported formats for date the command returns only new and/or live events. Supported formats for date
formatted time stamps include RFC3339Nano, RFC3339, `2006-01-02T15:04:05`, formatted time stamps include RFC3339Nano, RFC3339, `2006-01-02T15:04:05`,
`2006-01-02T15:04:05.999999999`, `2006-01-02Z07:00`, and `2006-01-02`. The local `2006-01-02T15:04:05.999999999`, `2006-01-02Z07:00`, and `2006-01-02`. The local

View file

@ -47,7 +47,7 @@ Import to docker via pipe and `STDIN`.
$ cat exampleimage.tgz | docker import - exampleimagelocal:new $ cat exampleimage.tgz | docker import - exampleimagelocal:new
Import with a commit message Import with a commit message.
$ cat exampleimage.tgz | docker import --message "New image imported from tarball" - exampleimagelocal:new $ cat exampleimage.tgz | docker import --message "New image imported from tarball" - exampleimagelocal:new

View file

@ -94,7 +94,7 @@ NETWORK ID NAME DRIVER
You can also filter for a substring in a name as this shows: You can also filter for a substring in a name as this shows:
```bash ```bash
$ docker ps --filter name=foo $ docker network ls --filter name=foo
NETWORK ID NAME DRIVER NETWORK ID NAME DRIVER
95e74588f40d foo bridge 95e74588f40d foo bridge
06e7eef0a170 foobar bridge 06e7eef0a170 foobar bridge
@ -104,8 +104,8 @@ NETWORK ID NAME DRIVER
The `id` filter matches on all or part of a network's ID. The `id` filter matches on all or part of a network's ID.
The following filter matches all networks with a name containing the The following filter matches all networks with an ID containing the
`06e7eef01700` string. `63d1ff1f77b0...` string.
```bash ```bash
$ docker network ls --filter id=63d1ff1f77b07ca51070a8c227e962238358bd310bde1529cf62e6c307ade161 $ docker network ls --filter id=63d1ff1f77b07ca51070a8c227e962238358bd310bde1529cf62e6c307ade161
@ -113,14 +113,14 @@ NETWORK ID NAME DRIVER
63d1ff1f77b0 dev bridge 63d1ff1f77b0 dev bridge
``` ```
You can also filter for a substring in a ID as this shows: You can also filter for a substring in an ID as this shows:
```bash ```bash
$ docker ps --filter id=95e74588f40d $ docker network ls --filter id=95e74588f40d
NETWORK ID NAME DRIVER NETWORK ID NAME DRIVER
95e74588f40d foo bridge 95e74588f40d foo bridge
$ docker ps --filter id=95e $ docker network ls --filter id=95e
NETWORK ID NAME DRIVER NETWORK ID NAME DRIVER
95e74588f40d foo bridge 95e74588f40d foo bridge
``` ```

View file

@ -25,7 +25,7 @@ To remove the network named 'my-network':
``` ```
To delete multiple networks in a single `docker network rm` command, provide To delete multiple networks in a single `docker network rm` command, provide
multiple network names or id's. The following example deletes a network with id multiple network names or ids. The following example deletes a network with id
`3695c422697f` and a network named `my-network`: `3695c422697f` and a network named `my-network`:
```bash ```bash

View file

@ -46,15 +46,15 @@ This command will delete all stopped containers. The command
the `rm` command which will delete them. Any running containers will not be the `rm` command which will delete them. Any running containers will not be
deleted. deleted.
$ docker rm -v redis $ docker rm -v redis
redis redis
This command will remove the container and any volumes associated with it. This command will remove the container and any volumes associated with it.
Note that if a volume was specified with a name, it will not be removed. Note that if a volume was specified with a name, it will not be removed.
$ docker create -v awesome:/foo -v /bar --name hello redis $ docker create -v awesome:/foo -v /bar --name hello redis
hello hello
$ docker rm -v hello $ docker rm -v hello
In this example, the volume for `/foo` will remain intact, but the volume for In this example, the volume for `/foo` will remain intact, but the volume for
`/bar` will be removed. The same behavior holds for volumes inherited with `/bar` will be removed. The same behavior holds for volumes inherited with