Commit Graph

3784 Commits

Author SHA1 Message Date
b141a44de0 Replace secrets with join tokens
Implement the proposal from
https://github.com/docker/docker/issues/24430#issuecomment-233100121

Removes acceptance policy and secret in favor of an automatically
generated join token that combines the secret, CA hash, and
manager/worker role into a single opaque string.

Adds a docker swarm join-token subcommand to inspect and rotate the
tokens.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 2cc5bd33eef038bf5721582e2410ba459bb656e9
Component: engine
2016-07-21 15:23:03 -07:00
7fe7aaea87 Merge pull request #24620 from yongtang/24270-service-list-filter
Allow partial name match for service ls --filter, node ls --filter, node tasks --filter
Upstream-commit: 7d84c715005dd123b0a63f23b207c12cb998786f
Component: engine
2016-07-20 21:25:06 +02:00
a996d4618b Allow partial name match for node ls, and node tasks
This fix is an extension to last commit to expand the partial
filter to node and task searches.

Additional integration tests have been added to cover the changes.

This fix fixes 24270.
This fix fixes 24112.

Note: A separate pull request will be opened on swarmkit.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: e734fa58eadb4dfaa33b4be275d6f8f29d899e78
Component: engine
2016-07-20 08:16:10 -07:00
257d1bc3de Merge pull request #24648 from mlaventure/fix-kill-test
Fix TestDaemonRestartWithKilledRunningContainer failures on RHEL systems
Upstream-commit: ffba13f43539ff58a0021c9353229507d50b66d5
Component: engine
2016-07-19 18:24:34 +00:00
ac1b563dd3 Update libcontainerd.AddProcess to accept a context
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
Upstream-commit: c02f82756e914081543bf05cb1815a48c02b1ebd
Component: engine
2016-07-19 08:24:39 -07:00
32ecbd59e9 Do not rely on "live" event anymore
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
Upstream-commit: 64483c3bdaa1887b8b932e0564362fbbff025dc0
Component: engine
2016-07-19 08:24:39 -07:00
6bac955e23 Merge pull request #24741 from dsau/24704-create-zfs-directory
Create zfs directory if it doesn't exist at startup.
Upstream-commit: 8a766b859ff2be52119087d55cdd4895326646ec
Component: engine
2016-07-19 13:22:54 +01:00
77d0030a64 Merge pull request #24755 from thaJeztah/fix-error-message
update "image delete" error to match actual behavior
Upstream-commit: f49fdb9d0b6345422a77c550b6d06ea7442f3f28
Component: engine
2016-07-18 22:47:55 -04:00
a9e33b5e83 Merge pull request #24476 from stevvooe/services-log-driver-support
swarm: add log driver support for services
Upstream-commit: 1796680381e7cb35eda14243a3fba1ac911ff908
Component: engine
2016-07-18 19:08:12 -07:00
962ced6b90 Allow partial name match for service ls --filter
This fix tries to address the issue raised in 24270 where it was
not possible to have a partial name match when list services
with name filter.

This fix updates swarmkit and allows prefix search when name is
provided as the filter for listing services.

An additional integration test is added to cover the changes.

This fix fixes 24270.

Note: A separate pull request will be opened on swarmkit.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 1d600ebcb5750c4c93356fae08e562d836ecee45
Component: engine
2016-07-18 17:53:08 -07:00
ae77cef214 Create zfs directory if it doesn't exist at startup.
Signed-off-by: Damian Smyth <damian@dsau.co>
Upstream-commit: 205bc6fc99872ba852fa7a158c106514d5b64179
Component: engine
2016-07-19 10:12:22 +10:00
3962d8ce71 Merge pull request #24754 from cpuguy83/24749_better_err_not_a_dir
Improve error message for ENOTDIR errors
Upstream-commit: bceacfa57f6386d908e91168cb4525ddc259ee63
Component: engine
2016-07-19 00:30:40 +02:00
4be1849e85 update "image delete" error to match actual behavior
The error message;

    unable to delete .... (must be forced) - image is referenced in one or more repositories

Looks to be incorrect

Given the following images:

    docker images | grep 2d36b1c0ea40
    registry                           2                                     2d36b1c0ea40        7 weeks ago         171.2 MB
    registry                           2.4.1                                 2d36b1c0ea40        7 weeks ago         171.2 MB

Removing the image by *id* fails:

    docker rmi 2d36b1c0ea40
    Error response from daemon: conflict: unable to delete 2d36b1c0ea40 (must be forced) - image is referenced in one or more repositories

However, after untagging one image:

    docker rmi registry:2
    Untagged: registry:2

Removing the image works:

    docker rmi 2d36b1c0ea40
    Untagged: registry:2.4.1
    Deleted: sha256:2d36b1c0ea40159adc8b36f7563f1d7a6d443384fe2611e8b393c1cb3ae2e6ad
    Deleted: sha256:7abfddbf4e61927307b6646010845eeb7513ecc6541f33ea6103b2493e36aa4e
    Deleted: sha256:f512d7699dbb2994fe15d30ee1d404e57b58c3c310617b4471db649680b4cfa0
    Deleted: sha256:7291e34714908270aeda93f1dc681485f9734d41314e2fdc6c11f32ffa782a21
    Deleted: sha256:548f6562929484f3d78267e4b1e31dcfeb9f303059668888b4423ce5501c7fbc
    Deleted: sha256:afe56b46629e6d8e0bfc36fed13395a7cfa2bd83b58bb489976ef13553eff20b
    Deleted: sha256:cf0c3bd5d6a0a14ebf96cc7d3df79a37774a70f3086273e09da71a86fe74fec2
    Deleted: sha256:c5fdaf8b055f544d0211043e687905315c3a0b71c1c08df07e473dd0a30e43c8

    docker images | grep 2d36b1c0ea40
    <empty>

This changes the error message to reflect that behavior

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: f0988dd39598a46d911abc54c19fc3377698d630
Component: engine
2016-07-18 23:17:55 +02:00
7262ef8faa Vendor in new containerd
This version introduces the following:
 - uses nanosecond timestamps for event
 - ensure events are sent once their effect is "live"

Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
Upstream-commit: 29b2714580d085533c29807fa337c2b7a302abb6
Component: engine
2016-07-18 11:44:24 -07:00
9c80a0e9b9 Merge pull request #24694 from tonistiigi/increase-timeout
Increase timeout for swarm requests
Upstream-commit: 0ec1adf9d1e3f0ea4fdcb98c83753d5575d3c52c
Component: engine
2016-07-18 18:15:37 +02:00
8453f0d859 Improve error message for ENOTDIR errors
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 83ae501f1d216600eebf182e7dc29e285c4b10bc
Component: engine
2016-07-18 11:12:33 -04:00
aa2ddf3393 swarm: add log driver support for services
Adds log driver support for service creation and update. Add flags
`--log-driver` and `--log-opt` to match `docker run`. Log drivers are
configured per service.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: e778ba2d5b1e5074fe413dffaa365f3d37b175c7
Component: engine
2016-07-15 21:39:27 -07:00
c4e34ed5c5 Improve flag help consistency, and update docs
This adds the `--live-restore` option to the documentation.

Also synched usage description in the documentation
with the actual description, and re-phrased some
flag descriptions to be a bit more consistent.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 64a8317a5a306dffd0ec080d9ec5b4ceb2479a01
Component: engine
2016-07-16 01:58:01 +02:00
ffdb429522 Increase timeout for swarm requests
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 85b1fdf15ce2ad1b373748554d3aa218e2eb5a5f
Component: engine
2016-07-15 11:03:08 -07:00
40f145b134 Fix daemon panic use wrong graphdriver with --live-restore flag
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: d9e8cea1b666cc22d6747482ad16600cb9dc6fa1
Component: engine
2016-07-15 05:05:28 -04:00
df6d3b4289 Merge pull request #24516 from crosbymichael/oom-score
Add --oom-score-adjust to daemon
Upstream-commit: ef322a3fbb31c2299e414f1c314f245c527ac3ea
Component: engine
2016-07-13 18:39:30 +00:00
5bac2725f4 Handle ingress sbox creation gracefully
Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: ed6641ad61d6d4f6475062ab2a2669a379caf574
Component: engine
2016-07-12 21:51:44 -07:00
53c33cc1be Add --oom-score-adjust to daemon
This adds an `--oom-score-adjust` flag to the daemon so that the value
provided can be set for the docker daemon's process.  The default value
for the flag is -500.  This will allow the docker daemon to have a
less chance of being killed before containers do.  The default value for
processes is 0 with a min/max of -1000/1000.

-500 is a good middle ground because it is less than the default for
most processes and still not -1000 which basically means never kill this
process in an OOM condition on the host machine.  The only processes on
my machine that have a score less than -500 are dbus at -900 and sshd
and xfce( my window manager ) at -1000.  I don't think docker should be
set lower, by default, than dbus or sshd so that is why I chose -500.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Upstream-commit: a894aec8d81de5484152a76d76b80809df9edd71
Component: engine
2016-07-12 15:53:15 -07:00
cbbd824f10 Merge pull request #24548 from cpuguy83/24167_fix_log_config_merge
Fix panic while merging log configs to nil map
Upstream-commit: 7a1442baf6e31b3c94a2e9fd92155a75c1987868
Component: engine
2016-07-12 23:40:47 +02:00
83f818387f Merge pull request #24549 from cpuguy83/fix_nil_meminfo
Fix panic when meminfo couldn't be read
Upstream-commit: 534c3e328fa14cee9b012b18faa35fd1571703ef
Component: engine
2016-07-12 23:05:27 +02:00
3abfcc9b91 Merge pull request #24546 from mavenugo/stend
Fixing a stale endpoint issue that blocks ingress network cleanup 
Upstream-commit: 933584f16fbd8fa1ffef691ed8d1673e7c896781
Component: engine
2016-07-12 16:40:19 -04:00
b8f5ee5430 Fix panic when meminfo couldn't be read
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 5f7b1b604c9e44477aee196b17fb4b5692cbbaa6
Component: engine
2016-07-12 15:30:21 -04:00
f1f9d4454d Fix panic while merging log configs to nil map
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 7dff31064824ed1f9b046fe5c29bd707e663ee0b
Component: engine
2016-07-12 15:24:42 -04:00
832af6ffb8 Merge pull request #24528 from rsippl/24526-empty-services-list
Return an empty services list if no services are running
Upstream-commit: 79432b436793b9850f50de38166740698aca41bf
Component: engine
2016-07-12 18:31:28 +00:00
e096d83b0e Fixing a stale endpoint issue that blocks ingress network cleanup
fixes #24400

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: a4926a4d92eb7940d079de01d7fafe43060fcd56
Component: engine
2016-07-12 11:27:58 -07:00
9b4a3ab43b Merge pull request #24518 from dmcgowan/overlay2-override-kernel-check
Allow option to override kernel check in overlay2
Upstream-commit: a44f0107023aa62d202b068c0a8d4b5ad0640838
Component: engine
2016-07-12 19:22:27 +02:00
048f3b1b85 Merge pull request #24504 from hqhq/soften_update_kmem
Soften limitation of update kernel memory
Upstream-commit: 110b2aecda9625dd5679733686d1cc169f87a463
Component: engine
2016-07-12 13:58:17 +02:00
52fb31b62e Return an empty services list if no services are running
Signed-off-by: Ralf Sippl <ralf.sippl@gmail.com>
Upstream-commit: c8e4e95db9b0d3115435b8f0e94c78a2e0cb92d0
Component: engine
2016-07-12 11:41:04 +02:00
1da671b499 Merge pull request #24229 from anusha-ragunathan/shutdown-plugins
Shutdown plugins during daemon shutdown.
Upstream-commit: b91e2dd9942f4c34b62de37c3862b9febd270b22
Component: engine
2016-07-11 22:14:50 -04:00
1a97e07ac0 Soften limitation of update kernel memory
Kernel memory is not allowed to be updated if container is
running, it's not actually a precise kernel limitation.

Before kernel version 4.6, kernel memory will not be accounted
until kernel memory limit is set, if a container created with
kernel memory initialized, kernel memory is accounted as soon
as process created in container, so kernel memory limit update
is allowed afterward. If kernel memory is not initialized,
kernel memory consumed by processes in container will not be
accounted, so we can't update the limit because the account
will be wrong.

So update kernel memory of a running container with kernel memory
initialized is allowed, we should soften the limitation by docker.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 08c7075c403b86111b2c393b49075a81a1d2263f
Component: engine
2016-07-12 08:07:24 +08:00
a5531ff991 Allow option to override kernel check in overlay2
Add option to skip kernel check for older kernels which have been patched to support multiple lower directories in overlayfs.

Fixes #24023

Signed-off-by: Derek McGowan <derek@mcgstyle.net> (github: dmcgowan)
Upstream-commit: ff98da0607c4d6a94a2356d9ccaa64cc9d7f6a78
Component: engine
2016-07-11 16:48:08 -07:00
495149133d Shutdown plugins during daemon shutdown.
Signed-off-by: Anusha Ragunathan <anusha@docker.com>
Upstream-commit: 863ab9ab134d0baef3c7e5d745eded891e87e734
Component: engine
2016-07-11 14:21:27 -07:00
4451288540 Merge pull request #24427 from swernli/remove_custom_images
Removing Custom Images support
Upstream-commit: b215c4c9748c008b5bdcd3ea267ac21e666da1ff
Component: engine
2016-07-11 14:01:41 -07:00
7fcae13aa7 Merge pull request #24474 from mavenugo/fix-24452
swarmkit expects network-id for as target
Upstream-commit: 36f3d4af233acd7c32caf94ed98ccee4585cc1f7
Component: engine
2016-07-11 20:59:38 +02:00
737108710c Merge pull request #24139 from runshenzhu/health-check
add health check in docker build-in swarm mode
Upstream-commit: e2fc1439a11cff5f719ae47265da135d26dd36ad
Component: engine
2016-07-11 09:43:59 -04:00
2768065432 Merge pull request #24468 from yongtang/24374-docker-info-seccomp
Fix seccomp output in `docker info`
Upstream-commit: bc5fa7c5e04f776ee5a4636a78b59462463b92ac
Component: engine
2016-07-10 04:22:26 -07:00
f2aefa4f7f swarmkit expects network-id for as target
For any operation that involves netwoks (other than network create),
swarmkit expects the target as network-id. Service upate was using
network-name as the target and that caused the issue.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: b32cfb32a3f654f27bc9d4356b36c6a7e5e53b21
Component: engine
2016-07-08 18:00:41 -07:00
f711cd5f01 Fix seccomp output in docker info
This fix tries to address the issue raised in #24374 where
`docker info` outputs seccomp support in Ubuntu 14.04 but
the seccomp wass not actually supported.

The issue is that in the current docker implementation, seccomp
support is only checked against the kernel by inspect CONFIG_SECCOMP
and CONFIG_SECCOMP_FILTER. However, seccomp might not be enabled
when building docker (through golang build flag).

This fix adds a supportSeccomp boolean variable. The supportSeccomp
is only set to true when seccomp is enabled when building docker.

This fix fixes #24374.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: a3b9dd89a1b19e7f84617b91f3756ae816c11035
Component: engine
2016-07-08 17:26:42 -07:00
8d74981897 Add logdrivers to executor from swarmkit
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 8a50315f3ce89b24e3556dba288b2ce7b4daf026
Component: engine
2016-07-08 13:33:40 -07:00
7ac8dc18c4 Update executor volumes from swarmkit
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 6586f4f0719ae59c4a2b74acd91a1a888a0018b5
Component: engine
2016-07-08 13:33:40 -07:00
e1639e03c6 Merge pull request #24358 from AkihiroSuda/fixdockertop
Validate arguments for `ps` in `docker top`
Upstream-commit: 152f5a5cedb062c26745cab81159b6bb2e05c0b1
Component: engine
2016-07-08 10:57:13 -07:00
eaf2bbac5f Merge pull request #24435 from cpuguy83/24350_cleanup_on_no_running_containers
Fix daemon not cleaned up w/ live restore enabled
Upstream-commit: a34534fe95f0b7378837a5d5993b1058d41a635e
Component: engine
2016-07-08 10:23:14 -07:00
4e31188a93 Merge pull request #24431 from mavenugo/revert
Check for swarm-mode network conflict during create network
Upstream-commit: e10c11e4a1ac39a408f7503b594207e481387c87
Component: engine
2016-07-08 09:41:34 -07:00
bff94672e9 daemon: ensure we set default options to stock runtime
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
Upstream-commit: 59162641cc20640afb785540b5f47178835de656
Component: engine
2016-07-08 15:58:06 +02:00
6e2ed85ac6 Validate arguments for ps in docker top
Fix #24357

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Upstream-commit: 253933220965574422aa6679255359d8bd15d435
Component: engine
2016-07-08 05:58:11 +00:00