Commit Graph

259 Commits (f7b0c9b47232be2df21f7bdf7329388629ed89d5)

Author SHA1 Message Date
Harald Albers 437b2748c2 bash completion for journald tag support
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:27 +00:00
Harald Albers 5d1e84419a Improve bash completion for `docker volume ls -f dangling`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:27 +00:00
Harald Albers 0c473c9e9c Let bash completion for `docker network rm` only complete custom networks
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:27 +00:00
David Calavera 0441148c7d Fix bash completion for `docker volume ls --dangling=false`.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2017-06-02 00:07:26 +00:00
Harald Albers 645055b37d bash completion for `docker daemon --userns-remap`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers f9a1ff0795 fix minor bash completion issue on OSX (compopt)
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers bdfbd1d9a6 bash completion for syslog over TLS log driver
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers d75f2e95a0 bash completion for `--cluster-store-opt kv.path discovery.{heartbeat,ttl}`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers b50ca03b9a remove bash completion for `docker tag -f`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers 58013afb39 bash completion for `docker ps --filter status=dead`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers 4808cc1282 bash completion for `docker cp --follow-link`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers b3bb4d45dd bash completion for `docker images -f dangling=false`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:26 +00:00
Harald Albers 869890dfbd Refactor handling of key specific subcompletions
The currently used idiom for handling key specific subcompletions
did not work here: behind `docker event -f type=network `, the completion
of networks triggered. The expected behaviour is not to complete
anything here.

In order to limit the scope of the corresponding PR, the new idiom is
currently only used in `docker events --filter`.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:25 +00:00
Harald Albers 4e97e95cd8 Support new events in bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:25 +00:00
Harald Albers 16c9a72852 bash completion for container linking and aliasing
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:24 +00:00
Harald Albers 09809fe27e bash completion for `docker network create --internal, --ipam-opt`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:24 +00:00
Harald Albers de6da285a3 bash completion for `--detach-keys`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:24 +00:00
Tibor Vass 7f6a7ed8d1 Rename authz to authorization for greater clarity
Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-02 00:07:23 +00:00
Harald Albers 9c8b6e05a4 bash completion for connecting non-running containers to networks
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:23 +00:00
Harald Albers caa120d3ca bash completion for `docker {build,create,run} --shm-size`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:22 +00:00
Harald Albers effe34067f bash completion for `docker update`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:22 +00:00
Harald Albers 3b7695959d bash completion for `docker daemon --cgroup-parent`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:22 +00:00
Harald Albers 442d408fc7 bash completion for `--isolation`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:22 +00:00
Harald Albers 9a63a5cdd6 Compute plugin list in bash completion for `docker daemon --authz-plugin`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:21 +00:00
Harald Albers c8195c7cd5 bash completion for `docker network ls --filter`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:21 +00:00
Harald Albers a36ca600a0 remove `--format` from bash completion for `docker network rm`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:21 +00:00
Harald Albers c227b6ac11 Better function names in bash completion
The new names make it easier to distinguish between helper functions and
functions that actually perform completion by modifying the global COMPOPT
variable.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:21 +00:00
Ma Shimiao 499d634f32 Add support for blkio read/write iops device
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
2017-06-02 00:07:21 +00:00
Harald Albers 57a8c59820 Use computed plugin lists in bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:21 +00:00
Vincent Demeester 1e3c5bbe15 Add --format support to images command
- rename `api/client/ps` to `api/client/formatter`
- add a a image formatter

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-02 00:07:21 +00:00
Harald Albers 9339b4abb5 bash completion for `docker daemon --authz-plugin`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:20 +00:00
Harald Albers b4a012656c Improve bash completion for `docker network disconnect`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:19 +00:00
Jessica Frazelle ac40ecf711 update bash completion for seccomp
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
2017-06-02 00:07:19 +00:00
Ma Shimiao 9480c4763d Add support for blkio read/write bps device
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
2017-06-02 00:07:19 +00:00
Vincent Demeester c6162061d9 Add format flag to network inspect
…for consistency as docker inspect and docker volume inspect supports it too

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-02 00:07:19 +00:00
Antonio Murdaca e9287cd43a Add OomScoreAdj to configure container oom killer preferences
libcontainer v0.0.4 introduces setting `/proc/self/oom_score_adj` to
better tune oom killing preferences for container process. This patch
simply integrates OomScoreAdj libcontainer's config option and adjust
the cli with this new option.

Signed-off-by: Antonio Murdaca <amurdaca@redhat.com>
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-06-02 00:07:19 +00:00
Dan Walsh 65120e8851 This patch adds --tmpfs as a option for mounting tmpfs on directories
It will Tar up contents of child directory onto tmpfs if mounted over

This patch will use the new PreMount and PostMount hooks to "tar"
up the contents of the base image on top of tmpfs mount points.

Signed-off-by: Dan Walsh <dwalsh@redhat.com>
2017-06-02 00:07:18 +00:00
Denis Gladkikh a148373062 Allow configurable metadata for Splunk log driver
Add support of `tag`, `env` and `labels` for Splunk logging driver.
Removed from message `containerId` as it is the same as `tag`.

Signed-off-by: Denis Gladkikh <denis@gladkikh.email>
2017-06-02 00:07:17 +00:00
Harald Albers d998542977 bash completion for `docker {run,create} --volume-driver`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:17 +00:00
Ma Shimiao e303d6cc9f Add support for blkio.weight_device
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
2017-06-02 00:07:17 +00:00
Harald Albers 2c0feab2a1 Align configuration of bash completion with existing values
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:16 +00:00
Harald Albers 7fa96238a6 Fix bash completion on systems where extglob is not set
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:16 +00:00
Harald Albers 2607803a34 bash completion for `docker stats --all`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:16 +00:00
David Calavera f9b805f16f Remove exec-driver global daemon option.
Each platform has only a driver now.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2017-06-02 00:07:15 +00:00
David Calavera c5ed875bd9 Remove LXC support.
The LXC driver was deprecated in Docker 1.8.
Following the deprecation rules, we can remove a deprecated feature
after two major releases. LXC won't be supported anymore starting on Docker 1.10.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2017-06-02 00:07:15 +00:00
Denis Gladkikh 1e2a27568b Add Splunk logging driver #16207
Allow to send Splunk logs using Http Event Collector

Signed-off-by: Denis Gladkikh <denis@gladkikh.email>
2017-06-02 00:07:14 +00:00
Harald Albers a41d4dbdde bash completion for log driver options `env` and `labels`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:14 +00:00
Harald Albers be7caf2647 bash completion can be configured to complete network IDs
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:14 +00:00
Harald Albers b20b7584de bash completion for `docker network inspect` supports multiple networks
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:14 +00:00
Harald Albers 6b43a0aa73 bash completion for `docker cp` supports copying both ways
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:14 +00:00
Harald Albers a2bbb2c61c bash completion for new `docker network create` options
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:14 +00:00
Harald Albers 28f2bdf335 Bash completion for restart policy `unless-stopped`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:13 +00:00
Harald Albers 321a5b38e7 bash completion: support for dm.use_deferred_* options
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:13 +00:00
Vincent Demeester 4c506e1df7 Deprecate -c cli short variant flag in docker cli
- build
- create

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-02 00:07:13 +00:00
Harald Albers c3c2867b15 Add missing options to bash completion for `docker import`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:13 +00:00
Harald Albers 9d4969150a bash completion: minor refactoring for consistency
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:13 +00:00
Harald Albers 0ef21aeab2 Add missing options to bash completion for `docker build`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:13 +00:00
Madhu Venugopal 3a779b2995 Added `network` to docker --help and help cleanup
Fixes https://github.com/docker/docker/issues/16909

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2017-06-02 00:07:13 +00:00
Harald Albers 3a89624209 Add bash completion for `docker inspect --size`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:12 +00:00
Harald Albers 966ebe7b62 Bash completion for `docker network`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:12 +00:00
Harald Albers 26294f39f2 Refactor bash completion: pull out subcommand parsing
`docker network` is the second command with subcommands.

This refactoring pulls out parsing and processing of subcommands
from `docker volume` completion and thus makes its logic available
for other commands.

Also enables `__docker_pos_first_nonflag` for subcommand completion.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:12 +00:00
Harald Albers 4fcea52287 Add bash completion for `--cluster-store-opt`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:12 +00:00
Jessica Frazelle 0afb6cc862 change flag name to better follow the other flags that start with disable;
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
2017-06-02 00:07:11 +00:00
Harald Albers 1b1a0a0835 Add bash completion for `--no-legacy-registry`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:10 +00:00
Harald Albers 3fce5e1084 bash completion for `docker daemon --cluster-*`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:10 +00:00
qhuang d5b1d055b8 Add support for memory reservation
Signed-off-by: qhuang <qhuang@10.0.2.15>
2017-06-02 00:07:10 +00:00
Harald Albers 7310f4a2bd Bash completion: avoid 'compopt: command not found' errors on Mac OS
The shell builtin `compopt` is not available on the outdated bash
version 3.2.57 that ships with Mac OS.
It is used in Docker's bash completion to suppress trailing spaces
in advanced completions of hash map options, e.g. `--log-opt`.

If `compopt` is not available, the new behavior is to do nothing,
i.e. the user will have to delete the additional space.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:10 +00:00
Harald Albers eb684d2bad bash completion: use generic `tag` log driver option
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:09 +00:00
Tim Hockin 8bdf17d8fe Add support for DNS options
Signed-off-by: Tim Hockin <thockin@google.com>
2017-06-02 00:07:09 +00:00
Harald Albers f5eb62c180 Fix bash completion when extglob is not set
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:09 +00:00
David Calavera 36a36bdaf5 Signal to stop a container.
Allow to set the signal to stop a container in `docker run`:
- Use `--stop-signal` with docker-run to set the default signal the container will use to exit.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2017-06-02 00:07:08 +00:00
Samuel Karp 0d2d916b13 Add awslogs driver for Amazon CloudWatch Logs
Signed-off-by: Samuel Karp <skarp@amazon.com>
2017-06-02 00:07:08 +00:00
Harald Albers 6c98ca574f bash completion for `docker volume`
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:08 +00:00
Vincent Demeester 1cf99bf127 Add docker ps --filter=… image completion
I missed that on #15919, thanks @albers

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-02 00:07:07 +00:00
Vincent Demeester 8387eacede Update shell completion on docker ps for ancestor
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-02 00:07:07 +00:00
Rory Hunter e7d0fd2b23 Make run and rmi bash completions configurable
Allow the user to configure how Docker's bash completion works for the
"events", "history", "inspect", "run", "rmi" and "save" commands through the
following environment variables:

DOCKER_COMPLETION_SHOW_IMAGE_IDS
  "none" - Show names only (default)
  "non-intermediate" - Show names and ids, but omit intermediate image IDs
  "all" - Show names and ids, including intermediate image IDs

DOCKER_COMPLETION_SHOW_TAGS
  "yes" - include tags in completion options (default)
  "no"  - don't include tags in completion options

Fixes #9474.

Signed-off-by: Rory Hunter <roryhunter2@gmail.com>
2017-06-02 00:07:06 +00:00
Qiang Huang 5731775665 Add support for kernel memory limit
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
2017-06-02 00:07:06 +00:00
Harald Albers 8d6fd1542f Fix bash completion for log driver options
This option was incorrectly ported to the new `daemon` subcommand
structure.

Beside the obvious effect that completion of `docker daemon --log-opt`
did not work, this also caused completion of `docker` and `docker xxx`
to fail on macs with

> bash: words: bad array subscript

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:05 +00:00
Tim Dettrick d0fa83e285 Revert "Revert "Add docker exec run a command in privileged mode""
This reverts commit 40b71adee390e9c06471b89ed845132b4ec80177.

Original commit (for which this is effectively a rebased version) is
72a500e9e5929b038816d8bd18d462a19e571c99 and was provided by Lei Jitang
<leijitang@huawei.com>.

Signed-off-by: Tim Dettrick <t.dettrick@uq.edu.au>
2017-06-02 00:07:05 +00:00
Harald Albers cefc964f4c Add storage options to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:05 +00:00
Harald Albers 0f17194e5f Add options for the json-file logging driver to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:05 +00:00
Harald Albers a287253ec5 Update bash completion for `docker run`
Also fixed sort order of options using `sort -d`

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:05 +00:00
Harald Albers 91300d7db0 Remove -h flag from completion and daemon reference
All docker subcommands support `-h` as an alias for `--help`
unless they have `-h` aliased to something else like `docker run`,
which uses `-h` for `--hostname`.

`-h` is not included in the help messages of the commands, though.

It ist visible in
* reference: only in `docker daemon` reference,
  see output of `grep -Rse --help=false docs`
* man pages: only in `docker` man page
  see output of `grep -RF '**-h**' man`

For consistency reasons, this commit removes `-h` as an alias for
`--help` from the reference page, man page and the bash completion.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:05 +00:00
Harald Albers 9fafadf6fc Add missing storage drivers to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:05 +00:00
Harald Albers c3bbab15c2 Add `docker ps --format` to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:05 +00:00
Harald Albers f3f1340aa0 Add `--config` to bash completion
The custom configuration will also be used in docker invocations made
by the completion script itself, just like `-H`.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:04 +00:00
Harald Albers 57062f2a44 Filter completions of `docker inspect` by `--type`
Completion now filters the images and containers by given
`--type`.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:04 +00:00
Harald Albers 3de0756fd1 Fix completion of commands after a global option with arg
Without this fix, `docker -l info ` would not complete the commands.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:04 +00:00
Harald Albers 35e75dc3e7 Add completion of global options to `docker daemon`
It's a bit confusing: the "global options" are valid as "global options"
for all client commands (i.e. all but daemon).
Example: `docker --log-level info run`

For `docker daemon`, these "global options" are only valid as "command
options".
Example: `docker daemon --log-level info`

As command completion cannot tell which command the user is going to
type next, completion for the daemon command has to allow illegal
syntaxes like
`docker --log-level info daemon --log-level info`

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:04 +00:00
Harald Albers 48ad74a01c Add `docker daemon` to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-02 00:07:04 +00:00
Dieter Reuter 371f131e2a Fix file mode for docker bash completion
A bash completion file shouldn't have a executable bit set.
Just change file mode to 644 (instead of 755).

Signed-off-by: Dieter Reuter <dieter.reuter@me.com>
2017-06-02 00:07:03 +00:00
Harald Albers 4f3ba975fb Complete all known driver options if no log driver was specified
Without this fix, `docker --log-opt ` would not complete anything
because the completions were driver specific.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:03 +00:00
Harald Albers 763ba5078d Fix problem with = in completion of docker global options
Without this fix, `docker --log-driver fluentd --log-opt fluentd-tag=b`
would complete `b` to `build`.
Completion of the commands has to be nailed to __docker_pos_first_nonflag

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:03 +00:00
Lei f793c1b50c Add ulimit to docker build.
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:07:02 +00:00
Harald Albers ad1ca76a0b 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>
2017-06-02 00:07:02 +00:00
Harald Albers f7eb7787da 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>
2017-06-02 00:07:02 +00:00
Harald Albers d3098f54ab Driver-specific completions for --log-opt
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:02 +00:00
Harald Albers e00293bec8 Add missing log drivers to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:02 +00:00
Mrunal Patel 7301088482 Adds documentation for additional groups.
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2017-06-02 00:07:01 +00:00
Harald Albers 23256b7438 Add some missing events to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:07:01 +00:00
Shishir Mahajan 24e7d40f42 Flag Addition: --type flag added for docker inspect command
Signed-off-by: Shishir Mahajan <shishir.mahajan@redhat.com>
2017-06-02 00:06:59 +00:00
Harald Albers 342d0cd04c Update bash completion for 1.7.0
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:56 +00:00
Jessica Frazelle 05c0da3b96 Revert "Add docker exec run a command in privileged mode"
This reverts commit 72a500e9e5929b038816d8bd18d462a19e571c99.

Signed-off-by: Jessica Frazelle <princess@docker.com>

Conflicts:
	daemon/execdriver/native/exec.go
	integration-cli/docker_cli_exec_test.go
	runconfig/exec.go
2017-06-02 00:06:56 +00:00
Harald Albers 9c413dcfc4 respect -H in bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:56 +00:00
Shishir Mahajan 7defdb0868 root dir for execdriver (/var/run/docker) should be configurable
Signed-off-by: Shishir Mahajan <shishir.mahajan@redhat.com>
2017-06-02 00:06:56 +00:00
Ahmet Alp Balkan a92995bc14 Add --since argument to docker logs cmd
Added --since argument to `docker logs` command. Accept unix
timestamps and shows logs only created after the specified date.

Default value is 0 and passing default value or not specifying
the value in the request causes parameter to be ignored (behavior
prior to this change).

Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2017-06-02 00:06:56 +00:00
Ma Shimiao edbbcc6dae add cpu.cfs_period_us support
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
2017-06-02 00:06:55 +00:00
Brian Goff 485c6d868b Allow pulling stats once and disconnecting.
Adds a `stream` query param to the stats API which allows API users to
only collect one stats entry and disconnect instead of keeping the
connection alive to stream more stats.

Also adds a `--no-stream` flag to `docker stats` which does the same

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2017-06-02 00:06:55 +00:00
Tianon Gravi 14411fae61 Only complete repos with "docker pull -a"
With this, `docker pull deb<tab>` will show all `debian:*` tags, as before, but `docker pull -a deb<tab>` will complete directly to just `debian`. 👍

Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2017-06-02 00:06:55 +00:00
Jessica Frazelle 734430c44c Add docs for `--exec-opt` and setting `native.cgroupdriver`.
update man pages.
update bash completion.

Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)

Docker-DCO-1.1-Signed-off-by: Jessie Frazelle <jess@docker.com> (github: jfrazelle)
2017-06-02 00:06:55 +00:00
Lei Jitang 433f49684e Add cpu cfs quota to build
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:55 +00:00
Lei Jitang 6c60a3415c Add support cpu cfs quota
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:54 +00:00
Lei Jitang cae7221b8d Add docker exec run a command in privileged mode
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:54 +00:00
Lei Jitang 3ca275df6d Add `-u|--user` flag to docker exec for running command as a different user
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:54 +00:00
Lei Jitang 26c3652d5e Add some missing option to bash completion
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:53 +00:00
Harald Albers d0fefccd8d Add missing filters to bash completion for docker images and docker ps
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:52 +00:00
Harald Albers 4d5758b252 Do not complete --cgroup-parent as _filedir
This is a follow-up on PR 11708, as suggested by tianon.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:52 +00:00
Lei Jitang 984a0d8dee Add some run option to bash completion
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:52 +00:00
Vincent Batts 1bca003519 .: remove trailing white spaces
blame tibor this one ;-)
```
find . -type f -not -name '*.png' -not -name '*.go' -not -name '*.md'
-not -name '*.tar' -not -name '*.pem' -not -path './vendor/*' -not -path
'./.git/*' -not -path '*/testdata/*' -not -path './docs/*images*' -not
-path '*/testfiles/*' -not -path './bundles/*' -not -path
'./docs/*static*/*' -not -path './docs/*article-img/*' -exec grep -HnEl
'[[:space:]]$' {} \; | xargs sed -iE 's/[[:space:]]*$//'
```

Signed-off-by: Vincent Batts <vbatts@redhat.com>
2017-06-02 00:06:51 +00:00
Tibor Vass 3574eda4c1 Revert "Dealing with trailing whitespaces"
The validation script from #10681 is too pedantic, and does not handle
well situations like:

```
cat <<EOF   # or <<-EOF
	Whether the leading whitespace is stripped out or not by bash
	it should still be considered as valid.
EOF
```

This reverts commit 4e65c1c319afffc325853b88c9aef0c42ec83482.

Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-02 00:06:51 +00:00
André Martins 1f934f1094 Dealing with trailing whitespaces
Created a validation that detects all trailing whitespaces from every
text file that isn't *.go, *.md, vendor/*,
docs/theme/mkdocs/tipuesearch*

Removed trailing whitespaces from every text file except from vendor/*
builder/parser/testfiles*, docs/theme/mkdocs/tipuesearch* and *.md

Signed-off-by: André Martins <martins@noironetworks.com>
2017-06-02 00:06:51 +00:00
Harald Albers fc2a7eea91 restrict bash completion for hostdir arg to directories
The previous state assumed that the HOSTPATH argument referred to a
file. As clarified by moxiegirl in PR #11305, it is a directory.
Adjusted completion to reflect this.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:51 +00:00
Harald Albers e2b5fc47e3 Updates to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:50 +00:00
Mabin 0be893a352 docs: api-enable-cors is deprecated,updated docs description
Signed-off-by: Mabin <bin.ma@huawei.com>
2017-06-02 00:06:49 +00:00
Dan Walsh e75c4494ed Need to support new linux capability AUDIT_READ
Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
2017-06-02 00:06:49 +00:00
Lei Jitang d8c4619844 Add --ulimit and --default-ulimit to bash completion
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:49 +00:00
Harald Albers 9690067dee Add bash completion for docker events --filter and --until.
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:49 +00:00
Lei Jitang 5bc113a640 Fix docker build and docker run bash completion
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2017-06-02 00:06:48 +00:00
Mike Dillon ceee2175bd Add bash completion for `docker rename`
Signed-off-by: Mike Dillon <mike@embody.org>
2017-06-02 00:06:47 +00:00
Harald Albers 3bb3eae782 Fix bash completion for docker run -d
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:47 +00:00
Harald Albers 063a4f574a Bash completion for docker kill
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:46 +00:00
Jessica Frazelle e6158378b5 Add completion for stats.
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
2017-06-02 00:06:46 +00:00
Harald Albers 0dafe480ab Add bash completions for daemon flags, simplify with extglob
Implementing the deamon flags the traditional way introduced even more
redundancy than usual because the same list of options with flags
had to be added twice.

This can be avoided by using variables in the case statements when
using the extglob shell option.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:46 +00:00
Harald Albers 3fb5792b25 Sort options in bash completion alphabetically
This introduces a sort order for options:

Arrange options sorted alphabetically by long name with the short
options immediately following their corresponding long form.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:44 +00:00
Harald Albers 1d3be0eae9 Add missing options to bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:44 +00:00
Harald Albers ce7267e597 Refactor completion for docker run and docker create
_docker_run and _docker_create had only one differing line.

This refactoring features:

- direct completion for both commands to the same function
- factor out the common arguments, sort & format them nicely
- compute the argument for _docker_pos_first_nonflag.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:43 +00:00
Harald Albers 3addb4d642 Minor bash completion cleanup
The -n and --networking options were removed because they are
unsupported. 
Bash completion should not reveal the existence of otherwise
undocumented unsupported options.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:42 +00:00
Harald Albers 055b224c90 Add missing options to bash completion for the run and create commands
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:42 +00:00
Harald Albers f1a49f2560 Fix support for --env-file in bash completion
Signed-off-by: Harald Albers <github@albersweb.de>
2017-06-02 00:06:37 +00:00
Tianon Gravi f071599471 Optimize the bash completion even further
The biggest/bestest change here is cutting down on the number of calls to Docker in the filtering helpers (`__docker_containers_running`, etc), especially calls to the really heavy `docker images`.

Signed-off-by: Andrew Page <admwiggin@gmail.com>
2017-06-02 00:06:36 +00:00
Michael Scharf e775b26a78 add bash completion support for pause and unpause
Signed-off-by: Michael Scharf <github@scharf.gr>
2017-06-02 00:06:36 +00:00
Dan Walsh 5619082f2b Add --security-opts options to allow user to customize security configuration
security-opts will allow you to customise the security subsystem.

For example the labeling system like SELinux will run on a container.

    --security-opt="label:user:USER"   : Set the label user for the container
    --security-opt="label:role:ROLE"   : Set the label role for the container
    --security-opt="label:type:TYPE"   : Set the label type for the container
    --security-opt="label:level:LEVEL" : Set the label level for the container
    --security-opt="label:disabled"    : Turn off label confinement for the container

Since we are passing a list of string options instead of a space separated
string of options, I will change function calls to use InitLabels instead of
GenLabels.  Genlabels interface is Depracated.

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
2017-06-02 00:06:35 +00:00
Tibor Vass 442ac2bc31 Add create to contrib/completion
Signed-off-by: Tibor Vass <teabee89@gmail.com>
2017-06-02 00:06:34 +00:00
Jessica Frazelle 98c2ff06ed Add exec to autocompletions
Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
2017-06-02 00:06:34 +00:00
Thomas LÉVEIL 0678d92b26 Add --force-rm to docker build command completion
Signed-off-by: Thomas LEVEIL <thomasleveil@gmail.com>
2017-06-02 00:06:33 +00:00
Tianon Gravi bfc4403d5f Update bash completion for "docker run --link" and "docker run -v" to complete on running containers and the local filesystem respectively
Also, add completion for "docker run -a" ("stdin", "stdout", and "stderr"), "docker run --env-file" (local filesystem), and some other minor code style tweaks.

Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2017-06-02 00:06:31 +00:00
Tianon Gravi 9bb81450d9 Update bash completion to only complete on directories as the argument to "docker build"
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2017-06-02 00:06:31 +00:00
Tianon Gravi a744ade2a8 Add bash completion for "docker rm -f" and complete on all containers instead of just stopped containers when "-f" is specified
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2017-06-02 00:06:30 +00:00
Tianon Gravi f66535d618 Update bash-completion to reflect ability to push single tags
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2017-06-02 00:06:29 +00:00
Victor Vieux a34d496738 cleanup all mentions of insert
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com> (github: vieux)
2017-06-02 00:06:29 +00:00