Commit Graph

898 Commits

Author SHA1 Message Date
7c4a2f84cd Add --prune to stack deploy.
Add to command line reference.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 9888942fbc
Component: cli
2017-06-02 00:10:58 +00:00
7ef9528844 Remove docs for dockerd --no-new-privileges
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: 48332a6aeb
Component: cli
2017-06-02 00:10:57 +00:00
03b30a9925 Enhance network inspect to show all tasks, local & non-local, in swarm mode
Signed-off-by: Santhosh Manohar <santhosh@docker.com>
Upstream-commit: 84ccb00486
Component: cli
2017-06-02 00:10:57 +00:00
55f899c468 Fix markdown in references for Kramdown
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 1f531be8ab
Component: cli
2017-06-02 00:10:57 +00:00
224077d070 Fix directive example to match description
The description claims the directive is appearing after a comment but
the sample Dockerfile has the directive appear after an instruction.
Changed the ordering of the lines to match the example's description.

Signed-off-by: Remy Suen <remy.suen@gmail.com>
Upstream-commit: 558b8923ab
Component: cli
2017-06-02 00:10:57 +00:00
15aa8d05a4 Fix typo in run.md documentation
Signed-off-by: John Laswell <john.n.laswell@gmail.com>
Upstream-commit: beacad8f6c
Component: cli
2017-06-02 00:10:57 +00:00
bab7965433 Fix description of docker run|create --stop-signal in help message
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: 2fcb361c55
Component: cli
2017-06-02 00:10:57 +00:00
33d9e6294f Add support for rollback flags
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 33ae729456
Component: cli
2017-06-02 00:10:56 +00:00
43638de628 Add support for the "rollback" failure action
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 8271c2a624
Component: cli
2017-06-02 00:10:56 +00:00
951746da22 Topology-aware scheduling
This adds support for placement preferences in Swarm services.

- Convert PlacementPreferences between GRPC API and HTTP API
- Add --placement-pref, --placement-pref-add and --placement-pref-rm to CLI
- Add support for placement preferences in service inspect --pretty
- Add integration test

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 0248b4df54
Component: cli
2017-06-02 00:10:56 +00:00
fec035ef1b remove Jekyll tags from CLI reference
These Markdown files are now embedded in a YAML
file for templating in the documentation, and
these special markers are no longer needed.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 8e7dd976f8
Component: cli
2017-06-02 00:10:56 +00:00
ded0855252 Add --stop-signal for service create and service update
This fix tries to address the issue raised in 25696 where
it was not possible to specify `--stop-signal` for `docker service create`
and `docker service update`, in order to use special signal to stop
the container.

This fix adds `--stop-signal` and update the `StopSignal` in `Config`
through `service create` and `service update`.

Related docs has been updated.

Integration test has been added.

This fix fixes 25696.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: e9457714cf
Component: cli
2017-06-02 00:10:56 +00:00
03bbd2f84a Remove incorrect duplicate phrase from build.md
A phrase from the "Text files" section in build.md was incorrectly duplicated under the "Tarball contexts" section.

Signed-off-by: Peter Jaffe <pjaffe@nevo.com>
Upstream-commit: 3a9b35dfa4
Component: cli
2017-06-02 00:10:56 +00:00
d9e38bf671 Add --add-host for docker build
Signed-off-by: Tony Abboud <tdabboud@hotmail.com>
Upstream-commit: 174d9f0097
Component: cli
2017-06-02 00:10:56 +00:00
1e8d9e0c5e Clarify why hosts in daemon.json does not work
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: e66bc57039
Component: cli
2017-06-02 00:10:55 +00:00
dba622ebee Delete dots to align with other commands description
Signed-off-by: yupengzte <yu.peng36@zte.com.cn>
Upstream-commit: 21f6dce0a0
Component: cli
2017-06-02 00:10:55 +00:00
a7d5248d4a [Docs] Add docs for stating stopped containers
This commit adds docs with example showing `docker stats` stopped
containers.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 12053f480b
Component: cli
2017-06-02 00:10:55 +00:00
2cc38cf538 fix the type
Signed-off-by: yupengzte <yu.peng36@zte.com.cn>
Upstream-commit: 6f3f9e384c
Component: cli
2017-06-02 00:10:55 +00:00
6669309a99 add rollback explanation to docker service update command document
Signed-off-by: erxian <evelynhsu21@gmail.com>
Upstream-commit: 1869390de8
Component: cli
2017-06-02 00:10:55 +00:00
400bf05854 Add daemon flag to set no_new_priv as default for unprivileged containers.
Signed-off-by: Daniel Zhang <jmzwcn@gmail.com>
Upstream-commit: 218740abc7
Component: cli
2017-06-02 00:10:55 +00:00
bc16584b47 Add --format to docker service ps
This fix tries to address the issue raised in 27189 where
it is not possible to support configured formatting stored in
config.json.

Since `--format` was not supported in `docker service ps`,
the flag `--format` has also been added in this fix.

This fix
1. Add `--format` to `docker service ps`
2. Add `tasksFormat` to config.json
3. Add `--format` to `docker stack ps`
4. Add `--format` to `docker node ps`

The related docs has been updated.

An integration test has been added.

This fix fixes 27189.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 1328bb4440
Component: cli
2017-06-02 00:10:55 +00:00
a1fc8b3905 Add example for --device-cgroup-rule to create reference
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
Upstream-commit: dd6886657d
Component: cli
2017-06-02 00:10:55 +00:00
b62be1dbab Convert script shebangs from "#!/bin/bash" to "#!/usr/bin/env bash"
This is especially important for distributions like NixOS where `/bin/bash` doesn't exist, or for MacOS users who've installed a newer version of Bash than the one that comes with their OS.

Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
Upstream-commit: e6a4e7507c
Component: cli
2017-06-02 00:10:54 +00:00
0efa0b9b49 fix typo
Signed-off-by: yupengzte <yu.peng36@zte.com.cn>
Upstream-commit: 225c67f074
Component: cli
2017-06-02 00:10:54 +00:00
07b8086695 Define bridge networks
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 022d972c38
Component: cli
2017-06-02 00:10:54 +00:00
dde4ebbb22 add expose and publish filter in swagger.yml and CLI docs for docker/master
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 1507e86ada
Component: cli
2017-06-02 00:10:54 +00:00
714b8afe3a add missing filter type and sort filter type in alphabets
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 4113925b25
Component: cli
2017-06-02 00:10:53 +00:00
020523b38b Standardized formatting of CLI reference commands
Command name should be a H1

Only Description, Examples, and Related Commands should be H2

Changed 'Related information' heading to 'Related commands' since 99% it is only linking commands

Added some examples where relevant

Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: ddadd3db49
Component: cli
2017-06-02 00:10:53 +00:00
a34431061a Removed unused image
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: cf4b3715ed
Component: cli
2017-06-02 00:10:53 +00:00
021a712fcb Add info about the relationship between swarm leave and node rm
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: c2893a6e1c
Component: cli
2017-06-02 00:10:53 +00:00
de4235c225 update events related doc and swagger.yml
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: d84da237bf
Component: cli
2017-06-02 00:10:53 +00:00
fd7bb178af Remove --init-path mention
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
Upstream-commit: b380c2eb63
Component: cli
2017-06-02 00:10:53 +00:00
5a52b7e76e Document --init flag for docker run
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
Upstream-commit: f571b363e6
Component: cli
2017-06-02 00:10:53 +00:00
5842bb356f Fix grammatical error in swarm_leave.md
Correct this sentence so it reads correctly. "to on a manager" should be
"on a manager".

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: e6889bf41b
Component: cli
2017-06-02 00:10:53 +00:00
a754ae967d Updated dockerd docs with note about user namespaces
Signed-off-by: Lewis Daly <lewisdaly@me.com>

Updated uid/gid reference to be more canonical - and signed commit

Signed-off-by: Lewis Daly <lewisdaly@me.com>

Editorial suggestion

I tried my hand at rewriting this a bit for readability. Can you please verify that the facts are correct, especially about the permission changes? You can feel free to squash my commit with yours so that it's signed. You'll need to pull the change from your fork to work on it locally.

Editorial suggestion

I tried my hand at rewriting this a bit for readability. Can you please verify that the facts are correct, especially about the permission changes? You can feel free to squash my commit with yours so that it's signed. You'll need to pull the change from your fork to work on it locally.
Upstream-commit: 50d1d4ecba
Component: cli
2017-06-02 00:10:52 +00:00
c2e799fae6 Add docker plugin upgrade
This allows a plugin to be upgraded without requiring to
uninstall/reinstall a plugin.
Since plugin resources (e.g. volumes) are tied to a plugin ID, this is
important to ensure resources aren't lost.

The plugin must be disabled while upgrading (errors out if enabled).
This does not add any convenience flags for automatically
disabling/re-enabling the plugin during before/after upgrade.

Since an upgrade may change requested permissions, the user is required
to accept permissions just like `docker plugin install`.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 02677bc06e
Component: cli
2017-06-02 00:10:52 +00:00
c4b571e726 Windows: Unify workdir handling
Signed-off-by: John Howard <jhoward@microsoft.com>

Working directory processing was handled differently for Hyper-V and Windows-Server containers, as annotated in the builder documentation (updated in this PR). For Hyper-V containers, the working directory set by WORKDIR was not created. This PR makes Hyper-V containers work the same as Windows Server containers (and the same as Linux).

Example (only applies to Hyper-V containers, so not reproducible under CI environment)
Dockerfile:
FROM microsoft/nanoserver
WORKDIR c:\installer
ENV GOROOT=c:\installer
ADD go.exe .
RUN go --help
Running on Windows Server 2016, using docker master without this change, but with daemon set to --exec-opt isolation=hyperv as it would be for Client operating systems.
PS E:\go\src\github.com\docker\docker> dockerd -g c:\control --exec-opt isolation=hyperv
time="2017-02-01T15:48:09.657286100-08:00" level=info msg="Windows default isolation mode: hyperv"
time="2017-02-01T15:48:09.662720900-08:00" level=info msg="[graphdriver] using prior storage driver: windowsfilter"
time="2017-02-01T15:48:10.011588000-08:00" level=info msg="Graph migration to content-addressability took 0.00 seconds"
time="2017-02-01T15:48:10.016655800-08:00" level=info msg="Loading containers: start."
time="2017-02-01T15:48:10.460820000-08:00" level=info msg="Loading containers: done."
time="2017-02-01T15:48:10.509859600-08:00" level=info msg="Daemon has completed initialization"
time="2017-02-01T15:48:10.509859600-08:00" level=info msg="Docker daemon" commit=3c64061 graphdriver=windowsfilter version=1.14.0-dev
First with no explicit isolation:
PS E:\docker\build\unifyworkdir> docker build --no-cache .
Sending build context to Docker daemon  10.1 MB
Step 1/5 : FROM microsoft/nanoserver
 ---> 89b8556cb9ca
Step 2/5 : WORKDIR c:\installer
 ---> 7e0f41d08204
Removing intermediate container 236c7802042a
Step 3/5 : ENV GOROOT c:\installer
 ---> Running in 8ea5237183c1
 ---> 394b70435261
Removing intermediate container 8ea5237183c1
Step 4/5 : ADD go.exe .
 ---> e47401a1745c
Removing intermediate container 88dcc28e74b1
Step 5/5 : RUN go --help
 ---> Running in efe90e1b6b8b
container efe90e1b6b8b76586abc5c1dc0e2797b75adc26517c48733d90651e767c8463b encountered an error during CreateProcess: failure in a Windows system call: The directory name is invalid. (0x10b) extra info: {"ApplicationName":"","CommandLine":"cmd /S /C go --help","User":"","WorkingDirectory":"C:\\installer","Environment":{"GOROOT":"c:\\installer"},"EmulateConsole":false,"CreateStdInPipe":true,"CreateStdOutPipe":true,"CreateStdErrPipe":true,"ConsoleSize":[0,0]}
PS E:\docker\build\unifyworkdir>
Then forcing process isolation:
PS E:\docker\build\unifyworkdir> docker build --isolation=process --no-cache .
Sending build context to Docker daemon  10.1 MB
Step 1/5 : FROM microsoft/nanoserver
 ---> 89b8556cb9ca
Step 2/5 : WORKDIR c:\installer
 ---> 350c955980c8
Removing intermediate container 8339c1e9250c
Step 3/5 : ENV GOROOT c:\installer
 ---> Running in bde511c5e3e0
 ---> b8820063b5b6
Removing intermediate container bde511c5e3e0
Step 4/5 : ADD go.exe .
 ---> e4ac32f8902b
Removing intermediate container d586e8492eda
Step 5/5 : RUN go --help
 ---> Running in 9e1aa235af5f
Cannot mkdir: C:\installer is not a directory
PS E:\docker\build\unifyworkdir>
Now compare the same results after this PR. Again, first with no explicit isolation (defaulting to Hyper-V containers as that's what the daemon it set to) - note it now succeeds 😄
PS E:\docker\build\unifyworkdir> docker build --no-cache .
Sending build context to Docker daemon  10.1 MB
Step 1/5 : FROM microsoft/nanoserver
 ---> 89b8556cb9ca
Step 2/5 : WORKDIR c:\installer
 ---> 4f319f301c69
Removing intermediate container 61b9c0b1ff6f
Step 3/5 : ENV GOROOT c:\installer
 ---> Running in c464a1d612d8
 ---> 96a26ab9a7b5
Removing intermediate container c464a1d612d8
Step 4/5 : ADD go.exe .
 ---> 0290d61faf57
Removing intermediate container dc5a085fffe3
Step 5/5 : RUN go --help
 ---> Running in 60bd56042ff8
Go is a tool for managing Go source code.

Usage:

        go command [arguments]

The commands are:

        build       compile packages and dependencies
        clean       remove object files
        doc         show documentation for package or symbol
        env         print Go environment information
        fix         run go tool fix on packages
        fmt         run gofmt on package sources
        generate    generate Go files by processing source
        get         download and install packages and dependencies
        install     compile and install packages and dependencies
        list        list packages
        run         compile and run Go program
        test        test packages
        tool        run specified go tool
        version     print Go version
        vet         run go tool vet on packages

Use "go help [command]" for more information about a command.

Additional help topics:

        c           calling between Go and C
        buildmode   description of build modes
        filetype    file types
        gopath      GOPATH environment variable
        environment environment variables
        importpath  import path syntax
        packages    description of package lists
        testflag    description of testing flags
        testfunc    description of testing functions

Use "go help [topic]" for more information about that topic.

The command 'cmd /S /C go --help' returned a non-zero code: 2
And the same with forcing process isolation. Also works 😄
PS E:\docker\build\unifyworkdir> docker build --isolation=process --no-cache .
Sending build context to Docker daemon  10.1 MB
Step 1/5 : FROM microsoft/nanoserver
 ---> 89b8556cb9ca
Step 2/5 : WORKDIR c:\installer
 ---> f423b9cc3e78
Removing intermediate container 41330c88893d
Step 3/5 : ENV GOROOT c:\installer
 ---> Running in 0b99a2d7bf19
 ---> e051144bf8ec
Removing intermediate container 0b99a2d7bf19
Step 4/5 : ADD go.exe .
 ---> 7072e32b7c37
Removing intermediate container a7a97aa37fd1
Step 5/5 : RUN go --help
 ---> Running in 7097438a54e5
Go is a tool for managing Go source code.

Usage:

        go command [arguments]

The commands are:

        build       compile packages and dependencies
        clean       remove object files
        doc         show documentation for package or symbol
        env         print Go environment information
        fix         run go tool fix on packages
        fmt         run gofmt on package sources
        generate    generate Go files by processing source
        get         download and install packages and dependencies
        install     compile and install packages and dependencies
        list        list packages
        run         compile and run Go program
        test        test packages
        tool        run specified go tool
        version     print Go version
        vet         run go tool vet on packages

Use "go help [command]" for more information about a command.

Additional help topics:

        c           calling between Go and C
        buildmode   description of build modes
        filetype    file types
        gopath      GOPATH environment variable
        environment environment variables
        importpath  import path syntax
        packages    description of package lists
        testflag    description of testing flags
        testfunc    description of testing functions

Use "go help [topic]" for more information about that topic.

The command 'cmd /S /C go --help' returned a non-zero code: 2
PS E:\docker\build\unifyworkdir>
Upstream-commit: 93a4f88991
Component: cli
2017-06-02 00:10:52 +00:00
b802dfee3e add endpoint mode a default value
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 2726013423
Component: cli
2017-06-02 00:10:52 +00:00
89a3d2f832 Add --format to docker service ls
This fix tries to improve the display of `docker service ls`
and adds `--format` flag to `docker service ls`.

In addition to `--format` flag, several other improvement:
1. Updates `docker stacks service`.
2. Adds `servicesFormat` to config file.

Related docs has been updated.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 7d3b3fda0d
Component: cli
2017-06-02 00:10:52 +00:00
2b3dc2cecc reference/commandline: small tfix
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
Upstream-commit: e000321b1d
Component: cli
2017-06-02 00:10:52 +00:00
d0dc5b7b7d Update opts.MemBytes to disable default, and move docker run/create/build to use opts.MemBytes
This fix made several updates:
1. Update opts.MemBytes so that default value will not show up.
   The reason is that in case a default value is decided by daemon,
   instead of client, we actually want to not show default value.
2. Move `docker run/create/build` to use opts.MemBytes for `--shm-size`
   This is to bring consistency between daemon and docker run
3. docs updates.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: d75f24fd9d
Component: cli
2017-06-02 00:10:52 +00:00
a83525f5e9 Add daemon option --default-shm-size
This fix fixes issue raised in 29492 where it was not
possible to specify a default `--default-shm-size` in daemon
configuration for each `docker run``.

The flag `--default-shm-size` which is reloadable, has been
added to the daemon configuation.
Related docs has been updated.

This fix fixes 29492.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 205ebd8d30
Component: cli
2017-06-02 00:10:52 +00:00
1397dfc743 Add capability filter to docker plugin ls
This fix adds `--filter capability=[volumedriver|authz]` to `docker plugin ls`.

The related docs has been updated.

An integration test has been added.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: ecfe6ab218
Component: cli
2017-06-02 00:10:51 +00:00
ef13b91211 Add --filter enabled=true for docker plugin ls
This fix adds `--filter enabled=true` to `docker plugin ls`,
as was specified in 28624.

The related API and docs has been updated.

An integration test has been added.

This fix fixes 28624.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: dd745df384
Component: cli
2017-06-02 00:10:51 +00:00
fa673da1ce Add publish and expose filter for docker ps --filter
This fix tries to address the enhancement proposal raised in
27178 for filtering based on published or exposed ports of
`docker ps --filter`.

In this fix, two filter options, `publish` and `expose` have
been added to take either `<port>[/<protocol>]` or `<from>-<to>[/<protocol>]`
and filtering on containers.

An integration test has been added to cover the changes.

This fix fixes 27178.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: aeda99b195
Component: cli
2017-06-02 00:10:51 +00:00
daeec5c32c Allow adding rules to cgroup devices.allow on container create/run
This introduce a new `--device-cgroup-rule` flag that allow a user to
add one or more entry to the container cgroup device `devices.allow`

Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
Upstream-commit: e9ad0f345f
Component: cli
2017-06-02 00:10:51 +00:00
7b73b7fd1c Fix for https://github.com/docker/docker.github.io/issues/1413
Signed-off-by: John Mulhausen <john@docker.com>
Upstream-commit: 706bbd52f0
Component: cli
2017-06-02 00:10:51 +00:00
3f499863f0 Fix syntax in example
Signed-off-by: Jeroen Franse <jeroenfranse@gmail.com>
Upstream-commit: 9fcf59f2e2
Component: cli
2017-06-02 00:10:51 +00:00
2a7cf7b5d0 Add --read-only for service create and service update
This fix tries to address the issue raised in 29972 where
it was not possible to specify `--read-only` for `docker service create`
and `docker service update`, in order to have the container's root file
system to be read only.

This fix adds `--read-only` and update the `ReadonlyRootfs` in `HostConfig`
through `service create` and `service update`.

Related docs has been updated.

Integration test has been added.

This fix fixes 29972.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 8235af9772
Component: cli
2017-06-02 00:10:51 +00:00
b865fb6b6b Add [OPTIONS] to usage of plugin disable|push
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: 5027bc6596
Component: cli
2017-06-02 00:10:51 +00:00