Commit Graph

32197 Commits

Author SHA1 Message Date
751e6f56a0 Merge pull request #35672 from tonistiigi/onbuild-test
Add testcase for onbuild command in multi stage build
Upstream-commit: b0cffdb10a2fbcec744588caddf3d0ddfc143967
Component: engine
2017-12-22 09:22:51 +01:00
ee811e7a56 Merge pull request #35851 from tonistiigi/test-names
integration-cli: clarify multi-stage tests names
Upstream-commit: 89140ac28cc413d0e961016b78addccdca4d3607
Component: engine
2017-12-22 00:25:17 +01:00
b8be0fb3b8 Merge pull request #35582 from asottile/use_base_containers_config
Fix environ substitutions in `docker commit --change ...`
Upstream-commit: a5de79b435735f8027ffc98072a33a83fc8dea28
Component: engine
2017-12-20 21:01:53 -08:00
aa8a79c526 Merge pull request #35845 from ndeloof/FIX35843
fix #35843 regression on health check workingdir
Upstream-commit: c36d6f5ab10d0dd4e5216fa3b8e2613de38c3ba2
Component: engine
2017-12-21 10:55:15 +09:00
02056dd212 Merge pull request #35838 from marcusmartins/marcus_swarmkit
Vendor docker/swarmkit to 713d79d
Upstream-commit: 9646d07d753b9d92678c625b6f43ed76a71fe83e
Component: engine
2017-12-20 23:47:10 +01:00
c61589a0f0 Add testcase for onbuild command in multi stage build
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: fe4ed9d78f496df5cac1eb914877f213f3f1c12c
Component: engine
2017-12-20 11:56:41 -08:00
d109b596b8 integration-cli: clarify multi-stage tests names
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: e90b7c06b4b08ca2935359667cfac4f05e33819b
Component: engine
2017-12-20 11:55:27 -08:00
2af5d43021 Fix environ substitutions in docker commit --change ...
The building machinery was being handed an uninitialized container
Config.  This changes it to use the target container's Config.

Resolves #30538

Signed-off-by: Anthony Sottile <asottile@umich.edu>
Upstream-commit: 0785836c4b440a8d4a5dfdb8df82e50f9f4d23a1
Component: engine
2017-12-20 11:03:38 -08:00
e0ed436e6c Add integration test for healthcheck workdir
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 5be2f2be243a52eb1b051c981bac5442b6e85606
Component: engine
2017-12-20 18:48:36 +01:00
2a820c0f5f fix #35843 regression on health check workingdir
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
Upstream-commit: 852a943c773382df09cdda4f29f9e93807523178
Component: engine
2017-12-20 14:04:51 +01:00
847487f5da Merge pull request #35778 from estesp/moby-governance
Add Moby TSC references/governance details
Upstream-commit: 267847712e720d624f78ef5364f474ff6635b725
Component: engine
2017-12-20 10:50:47 +01:00
50de5d926a Merge pull request #35812 from stevvooe/follow-conventions
daemon, plugin: follow containerd namespace conventions
Upstream-commit: 745278d24280614145819838b763c3a2d5349b7e
Component: engine
2017-12-19 15:55:39 -08:00
3f7322c602 Vendor docker/swarmkit to 713d79d
Revendor swarmkit to 713d79dc8799b33465c58ed120b870c52eb5eb4f to include
https://github.com/docker/swarmkit/pull/2473.

Signed-off-by: Marcus Martins <marcus@docker.com>
Upstream-commit: af73d31e60fd5c26d58bb8275785e628c3febdc0
Component: engine
2017-12-19 13:23:21 -08:00
760baaebbb Merge pull request #35805 from cpuguy83/fix_kill_containers_on_restart
Ensure containers are stopped on daemon startup
Upstream-commit: c3a9f5d00f48a1487ab005693e23bbaba04a0523
Component: engine
2017-12-19 12:19:47 -08:00
b225d1b061 Merge pull request #35726 from jahkeup/awslogs-batching
Fix awslogs batch size calculation
Upstream-commit: c8f7f4489ebac5b5dbf2d4e2b4fc1dd3f2d744dc
Component: engine
2017-12-19 20:44:33 +01:00
822fd111b3 Merge pull request #35808 from thaJeztah/prevent-panic-in-test
Prevent potential panic in TestLogsAPIUntil
Upstream-commit: 602bce175b40d77abf671b35afa9bf81c96b2b72
Component: engine
2017-12-19 11:16:00 -05:00
048a0b941a Ensure containers are stopped on daemon startup
When the containerd 1.0 runtime changes were made, we inadvertantly
removed the functionality where any running containers are killed on
startup when not using live-restore.
This change restores that behavior.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: e69127bd5ba4dcf8ae1f248db93a95795eb75b93
Component: engine
2017-12-18 14:33:45 -05:00
fd08bae89c Remove redundant build-tags
Files that are suffixed with `_linux.go` or `_windows.go` are
already only built on Linux / Windows, so these build-tags
were redundant.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 6ed1163c98703f8dd0693cecbadc84d2cda811c3
Component: engine
2017-12-18 17:41:53 +01:00
ef4dfd2f67 Remove Solaris files
Solaris is no longer being worked on, so these files
are now just dead code.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 1589cc0a85396e2768bfe9e558c7c2100dc3bc87
Component: engine
2017-12-18 17:22:25 +01:00
7e2ee76b7e Remove unused experimental code
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 16fe5a12891984ae5d0b28e737958566a13958ae
Component: engine
2017-12-18 17:07:48 +01:00
343f73cf3d Merge pull request #35811 from abhi/vendor
Vendoring swarmkit a6519e28ff2a558f5d32b2dab9fcb0882879b398
Upstream-commit: 26bc976ac9e379b4432f71394f069dfb1e4d7baf
Component: engine
2017-12-16 10:40:29 -06:00
435d4943db Merge pull request #35809 from cpuguy83/fix_container_zombies
Fix race conditions in libcontainerd process handling
Upstream-commit: 52656da9500eefedd69361849954e7d44b9a1513
Component: engine
2017-12-16 01:16:50 -08:00
ef43ef8bc9 Merge pull request #35794 from estesp/fix-overlay2-untarinuserns
Fix overlay2 storage driver inside a user namespace
Upstream-commit: 0862014431d40174a7b4e614ddcc0ee6e13ad570
Component: engine
2017-12-15 23:25:15 -08:00
ebbba75d0a daemon, plugin: follow containerd namespace conventions
Follow the conventions for namespace naming set out by other projects,
such as linuxkit and cri-containerd. Typically, they are some sort of
host name, with a subdomain describing functionality of the namespace.
In the case of linuxkit, services are launched in `services.linuxkit`.
In cri-containerd, pods are launched in `k8s.io`, making it clear that
these are from kubernetes.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: 521e7eba86df25857647b93f13e5366c554e9d63
Component: engine
2017-12-15 17:20:42 -08:00
e1fb11f9ea Vendoring swarmkit a6519e28ff2a558f5d32b2dab9fcb0882879b398
Signed-off-by: abhi <abhi@docker.com>
Upstream-commit: efae8db785189dc1fe9ce880d190beb2e26cb0fd
Component: engine
2017-12-15 11:37:17 -08:00
fbc087df98 Fix some missing synchronization in libcontainerd
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 647cec4324186faa3183bd6a7bc72a032a86c8c9
Component: engine
2017-12-15 12:54:38 -05:00
72249a1f2e Fix error handling for kill/process not found
With the contianerd 1.0 migration we now have strongly typed errors that
we can check for process not found.
We also had some bad error checks looking for `ESRCH` which would only
be returned from `unix.Kill` and never from containerd even though we
were checking containerd responses for it.

Fixes some race conditions around process handling and our error checks
that could lead to errors that propagate up to the user that should not.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: e55bead518e4c72cdecf7de2e49db6c477cb58eb
Component: engine
2017-12-15 10:09:55 -05:00
7ad7bb59be Merge pull request #35790 from thaJeztah/image-shortid
Remove support for referencing images by 'repository:shortid'
Upstream-commit: 6796e740fdcb8f446747a6b7890e71d4057b1082
Component: engine
2017-12-15 01:33:49 -08:00
b845d8f122 Prevent potential panic in TestLogsAPIUntil
Seen failing on Windows:

    22:27:52 ----------------------------------------------------------------------
    22:27:52 PANIC: docker_api_logs_test.go:152: DockerSuite.TestLogsAPIUntil
    22:27:52
    22:27:52 ... Panic: runtime error: index out of range (PC=0x45AC01)
    22:27:52
    22:27:52 d:/CI/CI-7caa30e89/go/src/runtime/asm_amd64.s:509
    22:27:52   in call32
    22:27:52 d:/CI/CI-7caa30e89/go/src/runtime/panic.go:491
    22:27:52   in gopanic
    22:27:52 d:/CI/CI-7caa30e89/go/src/runtime/panic.go:28
    22:27:52   in panicindex
    22:27:52 docker_api_logs_test.go:175
    22:27:52   in DockerSuite.TestLogsAPIUntil
    22:27:52 d:/CI/CI-7caa30e89/go/src/runtime/asm_amd64.s:509
    22:27:52   in call32
    22:27:52 d:/CI/CI-7caa30e89/go/src/reflect/value.go:434
    22:27:52   in Value.call
    22:27:52 d:/CI/CI-7caa30e89/go/src/reflect/value.go:302
    22:27:52   in Value.Call
    22:27:52 c:/gopath/src/github.com/docker/docker/vendor/github.com/go-check/check/check.go:816
    22:27:52   in suiteRunner.forkTest.func1
    22:27:52 c:/gopath/src/github.com/docker/docker/vendor/github.com/go-check/check/check.go:672
    22:27:52   in suiteRunner.forkCall.func1
    22:27:52 d:/CI/CI-7caa30e89/go/src/runtime/asm_amd64.s:2337
    22:27:52   in goexit
    22:27:54
    22:27:54 ----------------------------------------------------------------------

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: e77de7856bf212c764555ab8c2f346f2c529467c
Component: engine
2017-12-14 23:20:44 -08:00
600655d01d Remove support for referencing images by 'repository:shortid'
The `repository:shortid` syntax for referencing images is very little used,
collides with with tag references can be confused with digest references.

The `repository:shortid` notation was deprecated in Docker 1.13 through
5fc71599a0b77189f0fedf629ed43c7f7067956c, and scheduled for removal
in Docker 17.12.

This patch removes the support for this notation.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: a942c92dd77aff229680c7ae2a6de27687527b8a
Component: engine
2017-12-14 21:10:29 -08:00
57c4619d75 Windows: Case-insensitive filename matching against builder cache
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 7caa30e8937b65ad9fd61a8b811bba470d22809f
Component: engine
2017-12-14 13:49:40 -08:00
feccd72a49 Fix overlay2 storage driver inside a user namespace
The overlay2 driver was not setting up the archive.TarOptions field
properly like other storage backend routes to "applyTarLayer"
functionality. The InUserNS field is populated now for overlay2 using
the same query function used by the other storage drivers.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
Upstream-commit: 05b8d59015f8a5ce26c8bbaa8053b5bc7cb1a77b
Component: engine
2017-12-13 23:38:22 -05:00
63a4263b5f awslogs: Use batching type for ergonomics and correct counting
The previous bytes counter was moved out of scope was not counting the
total number of bytes in the batch. This type encapsulates the counter
and the batch for consideration and code ergonomics.

Signed-off-by: Jacob Vallejo <jakeev@amazon.com>
Upstream-commit: ad14dbf1346742f0607d7c28a8ef3d4064f5f9fd
Component: engine
2017-12-13 15:27:16 -08:00
9626c25157 Add Moby TSC references/governance details
Also added back some of the maintainer processes that were in
MAINTAINERS but moved to docker/opensource repo. I believe this
project's governance should be disconnected from docker/opensource as
project's remaining under docker/opensource will not use the Moby TSC.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
Upstream-commit: 449c870afbd21563a6df04445fbb136d3230629b
Component: engine
2017-12-13 16:51:46 -05:00
4a3429a762 Remove getBlkioWeightDevices in daemon_windows.go as it is not needed
Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 0866dee5fdb039adf73cd99e23bc5382a3dc8610
Component: engine
2017-12-13 17:31:28 +00:00
e5dd0c19d9 remove import of opencontainers/runc in windows
We are planning to remove supports for non-Linux platform in
runc (https://github.com/opencontainers/runc/pull/1654).  The current
import here is the only thing that i found in docker that is windows-related
so fixing this would remove the rest of windows code in runc.

This changes some functions in daemon_windows to be the same as
daemon_unix to use runtime-spec public API instead of runc.

Signed-off-by: Daniel Dao <dqminh89@gmail.com>
Upstream-commit: 4d1d486202a7c3977e51275c2efdba922375b0cd
Component: engine
2017-12-13 17:18:56 +00:00
4ee5590aac Merge pull request #35773 from arm64b/aarch64-multi-arch-imgs-replacement
Legacy images replacement with multi-arch ones on AArch64
Upstream-commit: 5dc791c2debd561f61f04ec5a947f261fe79b275
Component: engine
2017-12-13 14:56:14 +08:00
75b526540d Updated developer doc to explain included static cli and move of cli moby->docker-ce.
Signed-off-by: Brett Randall <javabrett@gmail.com>
Upstream-commit: b7109162ea5b1ce493144e5ba3116a20fc2fe068
Component: engine
2017-12-13 14:31:34 +11:00
6959a6fac2 Use commit-sha instead of tag for containerd
The `docker info` command compares the installed version
of containerd using a Git-sha. We currently use a tag for
this, but that tag is not returned by the version-API of
containerd, resulting in the `docker info` output to show:

    containerd version: 89623f28b87a6004d4b785663257362d1658a729 (expected: v1.0.0)

This patch changes the `v1.0.0` tag to the commit that
corresponds with the tag, so that the `docker info` output
does not show the `expected:` string.

This should be considered a temporary workaround; the check
for the exact version of containerd that's installed was needed
when we still used the 0.2.x branch, because it did not have
stable releases yet.

With containerd reaching 1.0, and using SemVer, we can likely
do a comparison for "Major" version, or make this a "packaging"
issue, and remove the check entirely (we can still _print_ the
version that's installed if we think it's usefule).

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 2c8018f4bd7f48bf8f35770dea68f81b9591bb58
Component: engine
2017-12-12 10:43:56 -08:00
5e0f8059c9 Merge pull request #35771 from thaJeztah/fix-flaky-testloTestLogsAPIUntil
Make TestLogsAPIUntil less flaky
Upstream-commit: 1082aa759ebd73971a92a48c6c7b253cf1605ae7
Component: engine
2017-12-12 10:12:35 -06:00
d81d63c977 Legacy images replacement with multi-arch ones on AArch64
Replace those legacy docker images prefixed by 'aarch64/' and 'arm64v8/'
with official multi-arch ones.

Signed-off-by: Dennis Chen <dennis.chen@arm.com>
Upstream-commit: 7fc697eb0b62557b4abaa3b9fc0cd44b5c1652ac
Component: engine
2017-12-12 05:47:17 +00:00
ec88074283 Merge pull request #35765 from ghislainbourgeois/35613-update-go-gelf-v2-for-bugfix
Update Graylog2/go-gelf vendoring. Fixes #35613
Upstream-commit: e48e938fc2e7e6c17d96c27e13e4d984ec68a9cb
Component: engine
2017-12-11 21:06:21 -08:00
c8a642f128 Make TestLogsAPIUntil less flaky
Commit ee594dcb7d42f95048c9047d86c61447243db3cd removed the
`sleep 0.5` from this test, because sleep has a full-second
precision. However, in some cases, all three log-entries
are output at the same time, causing the `--until` filter
to fail.

This patch adds back a `sleep`, but uses 1 second instead.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 1360f0dc9a5460bccf7974f7718d031435b883f3
Component: engine
2017-12-11 18:28:29 -08:00
209f0e3356 Merge pull request #35768 from thaJeztah/fix-healthcheck-typo
Fix typo in log-message
Upstream-commit: b687d6379db06bf0305d75c15f8f0e7f0dbeb921
Component: engine
2017-12-11 17:52:53 -06:00
90cb59fabc Merge pull request #35732 from rhvgoyal/error-info
devmapper: Log fstype and mount options during mount error
Upstream-commit: f5416e76702e8becb34d1e9843d0e2cd0f9f95bf
Component: engine
2017-12-11 14:37:30 -08:00
d586c2cf19 Update Graylog2/go-gelf vendoring. Fixes #35613
Signed-off-by: Ghislain Bourgeois <ghislain.bourgeois@gmail.com>
Upstream-commit: f9f3c49302fc80e586e3cb10af43114929556b47
Component: engine
2017-12-11 15:55:50 -05:00
6c564b6785 Fix vendoring of go-gelf to point to specific commit ID
Signed-off-by: Ghislain Bourgeois <ghislain.bourgeois@gmail.com>
Upstream-commit: 5bc11021250e39e71ca9edf62ce5c33f15c3756f
Component: engine
2017-12-11 15:53:11 -05:00
eae25b27ea Fix typo in log-message
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 5c3418e38b9603e8ff582d53c2face57f0f01cce
Component: engine
2017-12-11 10:59:51 -08:00
ef0d4a2bec devmapper: Log fstype and mount options during mount error
Right now we only log source and destination (and demsg) if mount operation
fails. fstype and mount options are available easily. It probably is a good
idea to log these as well. Especially sometimes failures can happen due to
mount options.

Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Upstream-commit: f728d74ac5d185adaa5f1a88eadc71217806859f
Component: engine
2017-12-11 13:27:14 -05:00
099ae9b4b0 Disallow using legacy (V1) registries
Interacting with v1 registries was deprecated in Docker 1.8.3, disabled by default
in Docker 17.06, and scheduled for removal in Docker 17.12.

This patch disallows enabling V1 registry through the `--disable-legacy-registry`
option, and the `"disable-legacy-registry": false` option in the daemon configuration
file. The actual V1 registry code is still in place, and will be removed separately.

With this patch applied:

    $ dockerd --disable-legacy-registry=false
    ERROR: The '--disable-legacy-registry' flag has been removed. Interacting with legacy (v1) registries is no longer supported

Or, when setting through the `daemon.json` configuration file

    $ mkdir -p /etc/docker/
    $ echo '{"disable-legacy-registry":false}' > /etc/docker/daemon.json
    $ dockerd
    ERROR: The 'disable-legacy-registry' configuration option has been removed. Interacting with legacy (v1) registries is no longer supported

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 8d6df8a0addc9a37b48c5a1827dd3f65f2ed57cf
Component: engine
2017-12-09 02:24:43 -08:00