Commit Graph

4255 Commits

Author SHA1 Message Date
9cb45952e0 Replace all "Filter" field with "Filters" for consistency
In file `api/types/client.go`, some of the "*Options{}" structs own a
`Filters` field while some else have the name of `Filter`, this commit
will rename all `Filter` to `Filters` for consistency. Also `Filters`
is consistent with API with format `/xxx?filters=xxx`, that's why
`Filters` is the right name.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 89a6966726941b4b7f0431ab214013cf9c655c25
Component: engine
2016-11-01 23:09:30 +08:00
34bac6f06e Fix bunch of typos
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: e6866492c4492db3bb9546afa2fbaed20f4c1883
Component: engine
2016-10-29 15:03:26 +08:00
0be42defbd Merge pull request #24698 from jhorwit2/jah/clist-health-filter-format
Fixes #24022 - Adds container health support to docker ps filter/format
Upstream-commit: 515e5dade7a006dbd2c42880f1af695da22ece60
Component: engine
2016-10-29 06:56:06 +02:00
4e9b278e51 Merge pull request #27840 from estesp/add-userns-status-to-info
Add "userns" to `docker info` security options output
Upstream-commit: 1fb9c4e89188f48c79889f6128fdec865bed467d
Component: engine
2016-10-29 02:58:34 +02:00
68b003581b Add "userns" to docker info security options output
If user namespaces is enabled on the daemon, reveal that via docker info
by adding "userns" to the list of security options reported by the
info endpoint.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
Upstream-commit: ae74092e450f1f2665b90257b65513cc0c19702f
Component: engine
2016-10-28 19:16:57 -04:00
86df94b9ba Merge pull request #27369 from cezarsa/hc
Add --health-* flags to service create and update
Upstream-commit: f860289131e36ad2dde5ebe60d15a86fd97934b5
Component: engine
2016-10-28 21:59:52 +02:00
5b866e7f54 Adds container health support to docker ps filter
Signed-off-by: Josh Horwitz <horwitzja@gmail.com>
Upstream-commit: 1a149a0ea59b6653e0ba14599476bfe19c4c33f3
Component: engine
2016-10-28 15:43:04 -04:00
c8cb7f1f85 Merge pull request #27842 from Microsoft/jjh/supportdiff
Windows: support docker diff
Upstream-commit: 9aa75016967ef36753f7e270bed03d9805b84ad8
Component: engine
2016-10-28 12:41:08 -07:00
3ea22f139e Merge pull request #26709 from boucher/checkpoint-dir
Allow providing a custom storage directory for docker checkpoints
Upstream-commit: b57f321a4a6ee3e14079b2913d5f90df0be49689
Component: engine
2016-10-28 11:12:44 -07:00
3b745bdb00 Merge pull request #26464 from vdemeester/11065-stop-signal-and-restart-policies
Taking stop-signal into account when docker kill
Upstream-commit: 9e436c9aad389de27f008cbf404fd907b23baa25
Component: engine
2016-10-28 11:08:55 -07:00
22458c8162 Windows: support docker diff
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 4fac603682747476a12dba0df79c10e919eddefb
Component: engine
2016-10-28 11:06:54 -07:00
28336d95ca Merge pull request #26659 from yongtang/26341-fixed-cidr-multiple-addresses-bridge
Fix issue for `--fixed-cidr` when bridge has multiple addresses
Upstream-commit: 1e989abefba1a424b95d3fc1474e489ace747598
Component: engine
2016-10-28 11:05:01 -07:00
bf7ee1cb20 Merge pull request #26837 from AkihiroSuda/newtmpfs
api: add TypeTmpfs to api/types/mount
Upstream-commit: 87ddc8b0a51248da4f9ab60b92901425c888282f
Component: engine
2016-10-28 19:21:26 +02:00
c05d99582c Add --health-* commands to service create and update
A HealthConfig entry was added to the ContainerSpec associated with the
service being created or updated.

Signed-off-by: Cezar Sa Espinola <cezarsa@gmail.com>
Upstream-commit: 7bd2611789e6898576f7229255c238f7c1129293
Component: engine
2016-10-28 15:19:08 -02:00
0e3402d520 Allow providing a custom storage directory for docker checkpoints
Signed-off-by: boucher <rboucher@gmail.com>
Upstream-commit: bd7d51292c399edba5f339e6be55fac6c0811ff5
Component: engine
2016-10-28 07:56:05 -04:00
ecffd5b73a api: add TypeTmpfs to api/types/mount
Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Upstream-commit: 18768fdc2e76ec6c600c8ab57d2d487ee7877794
Component: engine
2016-10-28 08:38:32 +00:00
0b8e22519c Merge pull request #27845 from cpuguy83/experimental_checks_daemon
error out if checkpoint specified on non-experimental
Upstream-commit: 0aaef963a880476d6637ad798c30520193ee04e3
Component: engine
2016-10-27 20:42:09 -07:00
dad340cfb8 Merge pull request #25800 from vdemeester/25798-fix-event-actions
Fix 25798 : Allow "partial/prefix" filter for health_status, exec_create and exec_start events
Upstream-commit: 10d77b878c473d5e85318aa889a74f1a31559bea
Component: engine
2016-10-28 05:20:49 +02:00
e39e12ad3b Merge pull request #27839 from vdemeester/lets-clise-this
Small log formatting fixes
Upstream-commit: 5945ba64b28a371d9f82232890c8b92e8355971d
Component: engine
2016-10-28 05:20:24 +02:00
4168a25419 error out if checkpoint specified on non-experimental
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 3c0a2bb289994b190356a9753658e4cbe81a25bb
Component: engine
2016-10-27 17:43:57 -07:00
fede704b07 Merge pull request #25820 from crosbymichael/prom
Add metrics output to docker
Upstream-commit: 33474a11fea50d50c1d365b29b94b978b2b6fff7
Component: engine
2016-10-27 16:44:26 -07:00
781e5170af Fix some event filtering
Make it possible to use health_status, exec_start and exec_create as
is in event filter. This way, using `health_status` as filter will allow
to get all health_status events (healthy, unhealthy, …) instead of
having to us all combination (`health_status: healthy`, `health_status:
unhealthy`, …). Same goes for `exec_start` and `exec_create`.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 71d8313ad415b8ec6efff3e88f48b5465f30c9a9
Component: engine
2016-10-27 16:14:13 -07:00
eac48da2d6 Small log formatting fixes
… and clise to close 👼

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 2f7e9078466f0d1b3a6a83cc269bce4e0a3b05f0
Component: engine
2016-10-27 15:29:24 -07:00
2a9003b823 Add basic prometheus support
This adds a metrics packages that creates additional metrics.  Add the
metrics endpoint to the docker api server under `/metrics`.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Add metrics to daemon package

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

api: use standard way for metrics route

Also add "type" query parameter

Signed-off-by: Alexander Morozov <lk4d4@docker.com>

Convert timers to ms

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Upstream-commit: 3343d234f3b131d4be1d4ca84385e184633a79bd
Component: engine
2016-10-27 10:34:38 -07:00
72db6e475a Fix issue for --fixed-cidr when bridge has multiple addresses
This fix tries to address the issue raised in 26341
where multiple addresses in a bridge may cause `--fixed-cidr`
to not have the correct addresses.

The issue is that `netutils.ElectInterfaceAddresses(bridgeName)`
only returns the first IPv4 address.

This fix (together with the PR created in libnetwork )
changes `ElectInterfaceAddresses()` and `addresses()`
so that all IPv4 addresses are returned. This will allow the
possibility of selectively choose the address needed.

In `daemon_unix.go`, bridge address is chosen by comparing with
the `--fixed-cidr` first, thus resolve the issue in 26341.

This fix is tested manually, as is described in 26341:
```
brctl addbr cbr0
ip addr add 10.111.111.111/20 dev cbr0 label cbr0:main
ip addr add 10.222.222.222/12 dev cbr0 label cbr0:docker
ip link set cbr0 up
docker daemon --bridge=cbr0 --iptables=false --ip-masq=false --fixed-cidr=10.222.222.222/24
docker run --rm busybox ip route get 8.8.8.8 | grep -Po 'src.*'
src 10.222.222.0
```

This fix fixes 26341.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: e9c4c513d11e6c3986f8858b9a11535d61cfdf74
Component: engine
2016-10-26 20:11:29 -07:00
3affb6aba8 Implementing support for --cpu-rt-period and --cpu-rt-runtime so that
containers may specify these cgroup values at runtime. This will allow
processes to change their priority to real-time within the container
when CONFIG_RT_GROUP_SCHED is enabled in the kernel. See #22380.

Also added sanity checks for the new --cpu-rt-runtime and --cpu-rt-period
flags to ensure that that the kernel supports these features and that
runtime is not greater than period.

Daemon will support a --cpu-rt-runtime flag to initialize the parent
cgroup on startup, this prevents the administrator from alotting runtime
to docker after each restart.

There are additional checks that could be added but maybe too far? Check
parent cgroups to ensure values are <= parent, inspecting rtprio ulimit
and issuing a warning.

Signed-off-by: Erik St. Martin <alakriti@gmail.com>
Upstream-commit: 56f77d5ade945b3b8816a6c8acb328b7c6dce9a7
Component: engine
2016-10-26 11:33:06 -04:00
ad6d3e7a11 cluster/container: correctly name swarm tasks
Even after a slew of PRs, this still wasn't quite right. Now, we ensure
the task name is calculared in one place in the executor, as least.

We'll have to follow this up once the `api/naming` package from SwarmKit
lands.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: 3b1af1751897680d32f4685e86d5dd1d9f3720b1
Component: engine
2016-10-25 14:17:57 -07:00
c0eb6c852a Merge pull request #27747 from Microsoft/jjh/clientisolationcomment
Windows: Add comment for containers on client SKUs
Upstream-commit: ff6db320f8a411d4a8b36a89ac28a85c453905ea
Component: engine
2016-10-25 13:37:25 -07:00
5572f883e7 Merge pull request #27698 from tonistiigi/cluster-config-refactor
Refactor swarm node config to struct
Upstream-commit: 844a3166e5c8ea5037a658f1e8f0628f5abc8dce
Component: engine
2016-10-25 13:29:55 -07:00
f83bc80e97 Windows: Add comment re client containers
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 87ab13add40ef616dbfc1cd00742f650343869cc
Component: engine
2016-10-25 10:30:00 -07:00
a3de26010f Merge pull request #27525 from AkihiroSuda/prune-network-cluster
add `docker network prune`
Upstream-commit: 11cd64f0dce35ad897ede7eb29babdc487e99617
Component: engine
2016-10-25 09:02:28 -07:00
e24e6d4206 Merge pull request #27467 from tonistiigi/attach-cb
Move stdio attach from libcontainerd backend to callback
Upstream-commit: 8ed31089c03c36954e95c2066b1f3724e2d5c849
Component: engine
2016-10-25 16:23:07 +02:00
4fb550ce0f add docker network prune
`docker network prune` prunes unused networks, including overlay ones.
`docker system prune` also prunes unused networks.

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Upstream-commit: 7e24c16086a9a4f38e241e51837f2be4877c04a6
Component: engine
2016-10-25 06:43:54 +00:00
db3c1eebdd Merge pull request #27699 from yongtang/27695-info-duplicate-nat-null-plugin
Remove duplicate `nat`, `null` in `docker info` for Windows
Upstream-commit: f901c5ed1c76d507a09079935e680f8c5bdd9070
Component: engine
2016-10-24 18:41:34 -07:00
cf0e8d8d85 Merge pull request #24533 from yongtang/24392-docker-info-label-duplicate-keys
Remove duplicate keys in labels of `docker info`
Upstream-commit: 411e7b4416fbac0601db1fa28b5152c23fcaf7bb
Component: engine
2016-10-24 18:12:28 -07:00
11895badbe Merge pull request #27223 from mlaventure/merge-experimental
Make experimental a runtime flag
Upstream-commit: ba41a5edac16857121779434cd80b86dcdb0ffda
Component: engine
2016-10-24 16:58:32 -07:00
179ef095e3 Refactor swarm node config to struct
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: b1014428c11a5495e713f2ab6df5aae45e8a46a6
Component: engine
2016-10-24 16:36:50 -07:00
4e1fb8f8f9 Merge pull request #27624 from erxian/remove-duplicate-err-judgement
remove duplicated error judgement in cluster.go
Upstream-commit: 09985ad89741dcc7cf0f8add500189d09d484b61
Component: engine
2016-10-24 16:11:53 -07:00
9798db7e18 Remove duplicate nat, null in docker info for Windows
This fix tries to address the issue raised in 27695 where
duplicate `nat` and `null` has been listed in `docker info`
for Windows.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 3347aba95762955fe17916e8cfc66aabbd6d66d6
Component: engine
2016-10-24 15:21:14 -07:00
9a299b360f Make experimental a runtime flag
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
Upstream-commit: 7781a1bf0fef748877326632b88e92fbf3c90daa
Component: engine
2016-10-24 15:20:01 -07:00
c42c998198 Merge pull request #26848 from miaoyq/del-a-redundant-err-return
Delete a redundant error return
Upstream-commit: 0ab13dda66613c403a06d69f8aff5d4b2e3b289e
Component: engine
2016-10-24 11:27:08 -07:00
051c4d005f Taking stop-signal into account when docker kill
If a container sets a stop-signal, taking it into account to disable or
not the restart policy.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: d2e64247e6dfd3257a7d015890aa2f168ff643a0
Component: engine
2016-10-24 11:10:14 -07:00
1883869e16 Move stdio attach from libcontainerd backend to callback
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 37a3be2449d2a314305615ffcc287a598a829dba
Component: engine
2016-10-24 00:20:36 -07:00
b33468451a Merge pull request #27460 from Microsoft/jjh/dockerpid
Windows: Calculate PID file after root
Upstream-commit: ce6cfef36d6fa52df6ebdd3dd996d6bebe0f308d
Component: engine
2016-10-22 13:41:42 +02:00
04894a8f04 Merge pull request #27596 from aaronlehmann/rolling-restart
Add force option to service update
Upstream-commit: 9058ec3be5edaa313caa02371ebe7d7ac64f2faa
Component: engine
2016-10-22 13:37:12 +02:00
2a18c9fa95 Merge pull request #26973 from allencloud/change-code-in-container-restore
change code in container restore
Upstream-commit: a6688959b4d574994f29af43d263caa83ee89ed2
Component: engine
2016-10-21 18:53:37 -07:00
36c938c12b Merge pull request #27117 from dnephin/swagger-gen
Add swagger.yaml and generate a few types from the spec
Upstream-commit: 3c385b9f6b820ae3badfbdcca589377e9a75e7fb
Component: engine
2016-10-21 18:15:28 -07:00
75231e91af Delete a redundant error return
Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>

update

Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>

update

Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>
Upstream-commit: 2d126f190d5a9c07b3d3aad93244055d8c9d5fc8
Component: engine
2016-10-22 08:53:57 +08:00
39b84d5fbe Add force option to service update
Currently, there's no way to restart the tasks of a service without
making an actual change to the service. This leads to us giving awkward
workarounds as in
https://github.com/docker/docker.github.io/pull/178/files, where we tell
people to scale a service up and down to restore balance, or make
unnecessary changes to trigger a restart.

This change adds a --force option to "docker service update", which
forces the service to be updated even if no changes require that.

Since rolling update parameters are respected, the user can use
"docker service --force" to do a rolling restart. For example, the
following is supported:

   docker service update --force --update-parallelism 2 \
   --update-delay 5s myservice

Since the default value of --update-parallelism is 1, the default
behavior is to restart the service one task at a time.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: c9fdf9abf8d6443598808809b900d96e04adfcb1
Component: engine
2016-10-21 17:43:27 -07:00
a9bf94a379 remove duplicated error judgement in cluster.go
Signed-off-by: erxian <evelynhsu21@gmail.com>
Upstream-commit: 75c51ad76b0b5995e9349cb369c9e8664f40855c
Component: engine
2016-10-21 14:28:10 +08:00