Commit Graph

742 Commits

Author SHA1 Message Date
0bcbde5ebd Split reader interface from logger interface
Implement new reader interface on jsonfile.
Moves jsonlog decoding from daemon to jsonfile logger.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: c9cf4a479a
Component: cli
2017-06-02 00:07:02 +00:00
7317401756 ps --format: Add config.js doc, fix gofmt, add integration tests
Re-add the docs from @calavera's PR to the moved cli cmd reference docs.
Fix gofmt and vet issues from carried commits
Add integration test for using format with --no-trunc and multi-names
Fix custom_test map order dependency on expected value check
Add docs to reference/commandline/ps.md
Remove "-F" flag option from original carried PR content

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Upstream-commit: 5f2fd60890
Component: cli
2017-06-02 00:07:02 +00:00
48f9bbaaa9 Docker ps custom formatting.
Docker-DCO-1.1-Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 1a9819b613
Component: cli
2017-06-02 00:07:02 +00:00
6ea0293e06 Expose new mount points structs in inspect.
Keep old hashes around for old api version calls.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: b3db7b8fce
Component: cli
2017-06-02 00:07:02 +00:00
738ed44f7d Second level completions for --log-opt
Advanced completion for some log driver options:
gelf-address, syslog-address, syslog-facility.

Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: ad1ca76a0b
Component: cli
2017-06-02 00:07:02 +00:00
622fdc9393 Completion: Add support for '=' in arguments to __docker_pos_first_nonflag
This solves several problems that arise from the special treatment of
"=" in Bash.
The fix was required as some log drivers have options in a key=value
form. It also addresses the --option=value and the negated boolean syntax
(--boolean=false).

Note that this is not a general fix for these problems, it is limited to
the __docker_pos_first_nonflag function.

Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: f7eb7787da
Component: cli
2017-06-02 00:07:02 +00:00
d423291b54 Driver-specific completions for --log-opt
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: d3098f54ab
Component: cli
2017-06-02 00:07:02 +00:00
31610116ef Add missing log drivers to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: e00293bec8
Component: cli
2017-06-02 00:07:02 +00:00
ef4e017a4c zsh: update zsh completion for docker command
zsh completion is updated with the content of
felixr/docker-zsh-completion.

 - felixr/docker-zsh-completion@a93e1cb7bd Fix completion of repositories with tags
 - felixr/docker-zsh-completion@590ea70596 Respect provided `--host` flag when invoking docker
 - felixr/docker-zsh-completion@6c557babaa Several cosmetic improvements
 - felixr/docker-zsh-completion@5b63cc591a Update completion for `inspect`
 - felixr/docker-zsh-completion@b7d8f2f7cc Order completions alphabetically
 - felixr/docker-zsh-completion@63f6a06224 Factor completion for `build`, `create` and `run`
 - felixr/docker-zsh-completion@ade49ee47f Enforce positional arguments being last
 - felixr/docker-zsh-completion@850b6b6d95 Update completion for build/commit/export/exec/history/import
 - felixr/docker-zsh-completion@01bfd8c075 Remove completion for `insert` and duplicate of `import`
 - felixr/docker-zsh-completion@c64a1d730a Update completion for `stats` to add `--no-stream` flag
 - felixr/docker-zsh-completion@5e81d78b52 Update completion for `log` to add `--since` flag
 - felixr/docker-zsh-completion@b3c146a1a2 Update completion for `run` to add `--group-add` flag
 - felixr/docker-zsh-completion@8d4f196ad8 Don't trigger expensive completion function for flags
 - felixr/docker-zsh-completion@bd5aaa124d Add completion for `--help` everywhere
 - felixr/docker-zsh-completion@3a67a0e8c4 Return appropriate status code on completion
 - felixr/docker-zsh-completion@4dfcb450ea Add Steve as a regular contributor.
 - felixr/docker-zsh-completion@996a1c6def Add completion for top-level flags
 - felixr/docker-zsh-completion@b6df75905f Ensure short/long option are not allowed twice
 - felixr/docker-zsh-completion@75b6a500a0 Complete repositories with tags only on repository match
 - felixr/docker-zsh-completion@5e6292135f Factorize completion of images/repositories/tags
 - felixr/docker-zsh-completion@1c504eb677 Handle repositories with ":"
 - felixr/docker-zsh-completion@0a05bf818b Update completion for `pause' and `unpause'
 - felixr/docker-zsh-completion@b3a63253e2 Containers name can include Swarm host

In summary:

 - Swarm support
 - Handling repositories with ":"
 - Rework how completion of images/repositories/tags work:
    - felixr/docker-zsh-completion@5e6292135f
    - felixr/docker-zsh-completion@75b6a500a0
    - felixr/docker-zsh-completion@a93e1cb7bd

The remaining changes are here to sync changes done in Docker repository
(mostly from PR #14074 and #14555, by @sdurrheimer). With some minor changes:

 - boolean flags don't complete their arguments (true/false)
 - reuse of `--host` argument is done with `$opt_arg` to avoid parsing
   error
 - build/create/run common options are factorized out
 - `--help` flag is handled differently
 - `pause` and `unpause` accepts several containers as far as I know, so
   the change is reverted
 - some more, but difficult to notice (more completion for some flags I think)

Some labels are reverted, mostly because I did the merge by copy/pasting
new options instead of modifying existing options.

This commit is partial. The way the `--help` option is handled triggered
a major change due to the way things are quoted. Those changes were
partially and programmaticaly reverted in this commit only to minimize
the changes to review. The next commit will restore the full changes.

Signed-off-by: Vincent Bernat <vincent@bernat.im>
Upstream-commit: c15fdb2435
Component: cli
2017-06-02 00:07:02 +00:00
f6603824ca Bump go-md2man to 1.0.3
Fixes an issue with curly braces being escaped when they should not be.
This was particularly an issue in places where `--format '{{ ...  }}'`
is used in the man docs.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 6db65bfd6c
Component: cli
2017-06-02 00:07:02 +00:00
d41bceaee4 docs: Updated for docker cp and its API changes
Documented changes to API to enable new `docker cp` behavior.

Added documentation on `docker cp` usage and behavior.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: 7e6f0aaece
Component: cli
2017-06-02 00:07:02 +00:00
08e6f56c35 Promote volume drivers from experimental to master.
Remove volume stubs and use the experimental path as the only path.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 356a7beb31
Component: cli
2017-06-02 00:07:02 +00:00
1591eec643 Update documentation according to opts updates
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: bbabc8172c
Component: cli
2017-06-02 00:07:02 +00:00
9e714bcbbe Fix man pages
Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Upstream-commit: 4a332a2e4e
Component: cli
2017-06-02 00:07:02 +00:00
20868b16c2 Simplify swappiness check
As suggested in https://github.com/docker/docker/pull/14004/files#r34022527

The concern there is we can't differentiate whether user explicitly
asked for an invalid value of -1 or he did not specify anything.

I don't think this would be a problem, because:
 - like all other default values like zero, we can't differentiate
   user specify it or not, most of which, zeros are also invalid, so
   default is default, we show these default values in help info,
   so users would know if they set value as default, it'll be like
   they set nothing.
 - we can't do this kind of string check in REST api request, so
   it'll make the behave different from docker command and RESTapi.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 7e4cf8a7ec
Component: cli
2017-06-02 00:07:02 +00:00
a40aa70084 add support for maximum log size, and max number of log files
Signed-off-by: wlan0 <sidharthamn@gmail.com>
Upstream-commit: 7dac74d442
Component: cli
2017-06-02 00:07:01 +00:00
e7122a31a2 Separate plugin sockets and specs.
Check if there is a plugin socket first under `/run/docker/plugins/NAME.sock`.
If there is no socket for a plugin, check `/etc/docker/plugins/NAME.spec` and
`/usr/lib/docker/plugins/NAME.spec` for spec files.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 412d99db51
Component: cli
2017-06-02 00:07:01 +00:00
2eca0b71ce Several cosmetic improvements in zsh completion
Signed-off-by: Steve Durrheimer <s.durrheimer@gmail.com>
Upstream-commit: 66c1b06bc4
Component: cli
2017-06-02 00:07:01 +00:00
e5d2433008 Zsh completion update for the following commits:
- Add fluentd logging driver to zsh completion #12876
- Add inspect --type flag to zsh completion #13187
- Respect -H option in zsh completion #13195
- Fix number of argument limit for pause and unpause in zsh completion

Signed-off-by: Steve Durrheimer <s.durrheimer@gmail.com>
Upstream-commit: 31c530fd42
Component: cli
2017-06-02 00:07:01 +00:00
4d9fd958f3 Modify man pages for image-naming
This PR adds recommendations in man pages to use only [a-z0-9-_.] when
naming and tagging images.  The purpose of this is to add consistency
and to make image naming caps rules seem less arbitrary.

This PR addresses confusion with:
1. BaseImage:Tagged (not allowed)
2. baseimage:Tagged (allowed)
3. baseimage/tagged:V1 (allowed)
4. baseimage/Tagged:V1 (not allowed)

Signed-off-by: Sally O'Malley <somalley@redhat.com>
Upstream-commit: bf09f5d572
Component: cli
2017-06-02 00:07:01 +00:00
7d2ef56baf zsh: remove Vincent Bernat from reviewers for ZSH completion
Signed-off-by: Vincent Bernat <vincent@bernat.im>
Upstream-commit: 3a6ca4b1d8
Component: cli
2017-06-02 00:07:01 +00:00
6dbeaaf4d7 Docs: fix commandline doc create.md and run.md
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 30dbdd7943
Component: cli
2017-06-02 00:07:01 +00:00
b93f7135a0 Adds documentation for additional groups.
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
Upstream-commit: 7301088482
Component: cli
2017-06-02 00:07:01 +00:00
0d5c36bb7c add --format flag to docker version
Signed-off-by: Patrick Hemmer <patrick.hemmer@gmail.com>
Upstream-commit: 90f2c9cf90
Component: cli
2017-06-02 00:07:01 +00:00
6553295dca Add some missing events to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: 23256b7438
Component: cli
2017-06-02 00:07:01 +00:00
2396d45eac Robert P.J. Day found this problems in man pages
Example in docker search has an extranious -t
docker rmi has a typo

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Upstream-commit: fe4c479f32
Component: cli
2017-06-02 00:07:01 +00:00
88ba0fa858 Add the memory swappiness tuning option to docker.
Memory swappiness option takes 0-100, and helps to tune swappiness
behavior per container.
For example, When a lower value of swappiness is chosen
the container will see minimum major faults. When no value is
specified for memory-swappiness in docker UI, it is inherited from
parent cgroup. (generally 60 unless it is changed).

Signed-off-by: Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
Upstream-commit: b553af956f
Component: cli
2017-06-02 00:07:01 +00:00
d25588047e Align 'docker commit' docs with the code
It was missing some variants and 'maintainer' isn't actually supported.
Also sorted the list of allowed cmds in the code just to make it easier
to diff with the docs.

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: c88c5588bf
Component: cli
2017-06-02 00:07:01 +00:00
bd5d4ae937 update reference to config file
`docker login` in 1.7 produces a config file in `~/docker/config.json`
instead of a `~/.dockercfg`.

Signed-off-by: Nate Brennand <nate.brennand@clever.com>
Upstream-commit: 839e00bb6f
Component: cli
2017-06-02 00:07:01 +00:00
2f100155de Add support for DOCKER_CONFIG/--config to specific config file dir
Carry #11675

Aside from what #11675 says, to me a key usecase for this is to support
more than one Docker cli running at the same time but each may have its
own set of config files.

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 408d7deaf7
Component: cli
2017-06-02 00:07:01 +00:00
9edf496500 Fix docs for oom-kill-disable
Addresses: #14440

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 5c0cf9dbf7
Component: cli
2017-06-02 00:07:01 +00:00
4ab1afc9a1 Update run.md
Put a space after the `###` in the Example section. On the github parser the result file looks ok, but in the docker page (<https://docs.docker.com/reference/run/>) looks ugly.

Signed-off-by: Átila Camurça <camurca.home@gmail.com>
Upstream-commit: fe4c3c26a3
Component: cli
2017-06-02 00:07:01 +00:00
2405e27120 Mention network driver plugins and point to protocol docs
Signed-off-by: Michael Bridgen <mikeb@squaremobius.net>
Signed-off-by: Tom Denham <tom.denham@metaswitch.com>
Upstream-commit: 6bfc07abd2
Component: cli
2017-06-02 00:07:01 +00:00
07e7c8577e Clarify that nproc is not for per container
Fix ulimit nproc spec in daemon

Signed-off-by: Harry Zhang <harryzhang@zju.edu.cn>
Upstream-commit: db7a29716e
Component: cli
2017-06-02 00:07:01 +00:00
bc7ab3cdf2 Fixing the table rendering in reference/run.md
Signed-off-by: Peeyush Gupta <gpeeyush@linux.vnet.ibm.com>
Upstream-commit: 7277df6cee
Component: cli
2017-06-02 00:07:00 +00:00
57bfdb01b7 Revert "Fix implicit DeviceMapper selection"
This reverts commit 0a376291b2213699f986a7bca1cc8c4f4ed00f8d.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 083daaeb2b
Component: cli
2017-06-02 00:07:00 +00:00
2ef0c4da9d daemon.md: fix placement of exec driver heading
Options for zfs storage driver were incorrectly placed
under 'exec driver options' header. Move the header to
the correct place.

Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Upstream-commit: 19e5936533
Component: cli
2017-06-02 00:07:00 +00:00
433942510e Fix example in cmdline help text to have correct output
Showing "$$ exit 13" caught my eye and wasn't correct.
While in there I also made it so the following paragraph didn't go past 80 chars

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 11e73c0252
Component: cli
2017-06-02 00:07:00 +00:00
f3727792b8 Update docker commit man page re: volumes
Update the man page for 'docker commit' to make explicit the fact that
'commit' does not save data in volumes.

Addresses comments in #7583

Signed-off-by: Lars Kellogg-Stedman <lars@redhat.com>
Upstream-commit: 569b77dda2
Component: cli
2017-06-02 00:07:00 +00:00
114a1b5710 Clarify .dockerignore example for Markdown files
The current documentation correctly states that dockerignore pattern
searches are non-recursive. However, the example given for Markdown
files seems to contradict this by saying that `*.md` will exclude *all*
Markdown files. This commit clarifies the situation by explicitly
specifying that `*.md` will only exclude files in the root directory of
the project.

Signed-off-by: Tim Wraight <tim.wraight@tangentlabs.co.uk>
Upstream-commit: 85ff60eb74
Component: cli
2017-06-02 00:07:00 +00:00
f73c587d92 Fix a broken anchor tag on the CLI builder page
Signed-off-by: Chris McKinnel <chrismckinnel@gmail.com>
Upstream-commit: c4541d3793
Component: cli
2017-06-02 00:07:00 +00:00
00bf9b7e19 Document the location of experimental binary
Some devs might want to download the binary directly,
especially for systems where the install script does not
work.

Signed-off-by: Ankush Agarwal <ankushagarwal11@gmail.com>
Upstream-commit: 54ebf2ac44
Component: cli
2017-06-02 00:07:00 +00:00
61c7fe428b Fix for broken link
The link pointed to experimental.md, but that didn't exist. It looks like README.md was intended. Probably experimental.md was renamed.

Signed-off-by: Leen Besselink <github@consolejunkie.net>
Upstream-commit: 572844ad99
Component: cli
2017-06-02 00:07:00 +00:00
758bcff07d Fix implicit DeviceMapper selection
DeviceMapper must be explicitly selected because the Docker binary might not be linked to the right devmapper library.

With this change, Docker fails fast if the driver detection finds the devicemapper directory but the driver is not the default option.
The option `override_udev_sync_check` doesn't make sense anymore, since the user must be explicit to select devicemapper, so it's being removed.
Docker fails to use devicemapper only if Docker has been built statically unless the option was explicit.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 1028f69f59
Component: cli
2017-06-02 00:07:00 +00:00
43f540b400 Unify docker commands' usage in man and help
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
Upstream-commit: 75186acbff
Component: cli
2017-06-02 00:06:59 +00:00
4aa2c173ed Flag Addition: --type flag added for docker inspect command
Signed-off-by: Shishir Mahajan <shishir.mahajan@redhat.com>
Upstream-commit: 24e7d40f42
Component: cli
2017-06-02 00:06:59 +00:00
8de5fd2e46 Plugins JSON spec.
Allow full configuration of external plugins via a JSON document.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 7cd538db6f
Component: cli
2017-06-02 00:06:59 +00:00
52722c7f40 Typo in memory-swap flag
Fixes #14253

Signed-off-by: Ankush Agarwal <ankushagarwal11@gmail.com>
Upstream-commit: f7e2399648
Component: cli
2017-06-02 00:06:59 +00:00
25210bf840 Closes #13323 and carries
Entering comments

Signed-off-by: Mary Anthony <mary@docker.com>
Upstream-commit: 5fbf370b98
Component: cli
2017-06-02 00:06:59 +00:00
f01f7d0493 Typo
Signed-off-by: Eric Sage <eric.david.sage@gmail.com>
Upstream-commit: 2feacfe882
Component: cli
2017-06-02 00:06:59 +00:00