Commit Graph

33439 Commits

Author SHA1 Message Date
bcde4812db Remove stray uses of "golang.org/x/net/context"
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 4c0a050ee24beb399b11c48829522e48f8d0b98a
Component: engine
2018-07-13 09:53:36 +02:00
882263fbf1 Merge pull request #37422 from thaJeztah/fix-linting-errors
Fix some golint and ineffassign issues
Upstream-commit: f9470d8189e25c297c6c7bd9ac592b6e5acd951e
Component: engine
2018-07-13 00:25:46 +02:00
dc41641256 Fix error string in docker CLI test
Signed-off-by: Sandeep Bansal <sabansal@microsoft.com>
Upstream-commit: 76ace9bb5e2c5ecdd02046956ab00f76c3b25a3a
Component: engine
2018-07-11 23:02:44 -07:00
6de0e3f629 Merge pull request #37436 from thaJeztah/bump_metalinter
Bump gometalinter to v2.0.6
Upstream-commit: 705774aa7683892fc214d2b028d226f24ad20f1c
Component: engine
2018-07-11 15:44:45 -07:00
c5fdcd4c55 Merge pull request #37437 from thaJeztah/format_fixes
Various formatting fixes / compilation issues caught by Go 1.11
Upstream-commit: 5fc12449d830ae9005138fb3d3782728fa8d137a
Component: engine
2018-07-11 23:14:19 +02:00
d799a9b46d Fix golint issues
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 35f7e7c50a131494c9d530800e80bf2da42fb89c
Component: engine
2018-07-11 22:19:03 +02:00
a174fffcfe Fix ineffassign linting
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: ddd8a6572d36a6d0db2aa21d697018f419a7b424
Component: engine
2018-07-11 22:18:45 +02:00
6029eff9d1 Merge pull request #37413 from yui-knk/do_not_Healthcheck_RUN_command
Ensure RUN instruction to run without Healthcheck
Upstream-commit: f0585d04d079d289b7b9cb572f8ee509f6768402
Component: engine
2018-07-11 20:38:03 +02:00
99d1e1cf76 loggerutils: build fixes, improve errors
There are two build errors when using go-1.11beta1:

> daemon/logger/loggerutils/logfile.go:367: Warningf format %q arg f.Name is a func value, not called
> daemon/logger/loggerutils/logfile.go:564: Debug call has possible formatting directive %v

In the first place, the file name is actually not required as error
message already includes it.

While at it, fix a couple of other places for more correct messages, and
make sure to not add a file name if an error already has it.

Fixes: f69f09f44c
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 09ad434f10cff48741322854a3003686b28295b5
Component: engine
2018-07-11 15:52:25 +02:00
d01a9704de aufs: fix Wrapf args
Fix the following go-1.11beta1 build error:

> daemon/graphdriver/aufs/aufs.go:376: Wrapf format %s reads arg #1, but call has 0 args

While at it, change '%s' to %q.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 2e30e9e6db42043cb2bd67d25a7152488c834f9f
Component: engine
2018-07-11 15:52:22 +02:00
14a71772f5 Compile fix
Go 1.11beta1 (rightfully) complains:

> 15:38:37 daemon/cluster/controllers/plugin/controller.go:183:
> Entry.Debugf format %#T has unrecognized flag #

This debug print was added by commit 72c3bcf2a5.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: a9a136572dc2a2c2ec5da320c4d0a32b5a15c550
Component: engine
2018-07-11 15:52:19 +02:00
2a7994f372 daemon/*.go: fix some Wrap[f]/Warn[f] errors
In particular, these two:
> daemon/daemon_unix.go:1129: Wrapf format %v reads arg #1, but call has 0 args
> daemon/kill.go:111: Warn call has possible formatting directive %s

and a few more.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 3737194b9f2875c10f3f2117c1816054ba0ff262
Component: engine
2018-07-11 15:51:51 +02:00
c5b67f5adc Bump gometalinter to v2.0.6
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: bda793d1d4b4000154d057afb9621f5123bb0dac
Component: engine
2018-07-11 15:41:15 +02:00
9ef9ed7750 Merge pull request #37424 from thaJeztah/bump_libnetwork
Bump libnetwork to d00ceed44cc447c77f25cdf5d59e83163bdcb4c9
Upstream-commit: 94a8f4d0d4af128d656fa571fff2dd2b59278717
Component: engine
2018-07-11 12:04:41 +01:00
2a39d8293c Merge pull request #37431 from tonistiigi/mountable-fix
builder: fix duplicate calls to mountable
Upstream-commit: e6aa71b190a87406e327ca08680e691d6f1fcfe5
Component: engine
2018-07-10 18:26:57 -07:00
4c7a4e64a3 builder: fix duplicate calls to mountable
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: ffa7233d1538363fe12ad609e720b8d75e8768de
Component: engine
2018-07-10 15:21:29 -07:00
5bd73ec5be Bump containerd daemon to v1.1.1
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: c083eb75953c266c4be9292cdeb7aad283ca47ba
Component: engine
2018-07-09 16:00:20 -07:00
15fd6dfa94 Merge pull request #37398 from mykeul/master
mkimage-alpine.sh: Removed the "-i -t" arguments from the smoke test calling printf (the…
Upstream-commit: c04f9ae9d7af14d0fb49bb84e46c03b871f59a5d
Component: engine
2018-07-09 14:50:53 -06:00
f626c687df Merge pull request #37419 from thaJeztah/pass_loglevel_to_containerd
Pass log-level to containerd
Upstream-commit: 42bd8e1b1034a9caaf0fb537a5dd4e855ade9fda
Component: engine
2018-07-09 21:59:47 +02:00
d3875eff05 Bump libnetwork to d00ceed44cc447c77f25cdf5d59e83163bdcb4c9
The absence of the file /proc/sys/net/ipv6/conf/all/disable_ipv6
doesn't appear to affect functionality, at least at this time.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: d58c4cbe6c781c78db352db2956e9949b8fc8609
Component: engine
2018-07-09 21:03:50 +02:00
730b7c1410 Merge pull request #37372 from ctelfer/scalable-lb
Improve scalability of the Linux load balancing
Upstream-commit: 328c089b5bca66594c4937e88cf9879879c4eed7
Component: engine
2018-07-09 20:06:37 +02:00
6d34b0ff1f Pass log-level to containerd
dockerd allows the `--log-level` to be specified, but this log-level
was not forwarded to the containerd process.

This patch sets containerd's log-level to the same as dockerd if a
custom level is provided.

Now that `--log-level` is also passed to containerd, the default "info"
is removed, so that containerd's default (or the level configured in containerd.toml)
is still used if no log-level is set.

Before this change:

containerd would always be started without a log-level set (only the level that's configured in `containerd.toml`);

```
root      1014  2.5  2.1 496484 43468 pts/0    Sl+  12:23   0:00 dockerd
root      1023  1.2  1.1 681768 23832 ?        Ssl  12:23   0:00  \_ docker-containerd --config /var/run/docker/containerd/containerd.toml
```

After this change:

when running `dockerd` without options (same as current);

```
root      1014  2.5  2.1 496484 43468 pts/0    Sl+  12:23   0:00 dockerd
root      1023  1.2  1.1 681768 23832 ?        Ssl  12:23   0:00  \_ docker-containerd --config /var/run/docker/containerd/containerd.toml
```

when running `dockerd --debug`:

```
root       600  0.8  2.1 512876 43180 pts/0    Sl+  12:20   0:00 dockerd --debug
root       608  0.6  1.1 624428 23672 ?        Ssl  12:20   0:00  \_ docker-containerd --config /var/run/docker/containerd/containerd.toml --log-level debug
```

when running `dockerd --log-level=panic`

```
root       747  0.6  2.1 496548 43996 pts/0    Sl+  12:21   0:00 dockerd --log-level=panic
root       755  0.7  1.1 550696 24100 ?        Ssl  12:21   0:00  \_ docker-containerd --config /var/run/docker/containerd/containerd.toml --log-level panic
```

combining `--debug` and `--log-level` (`--debug` takes precedence):

```
root       880  2.7  2.1 634692 43336 pts/0    Sl+  12:23   0:00 dockerd --debug --log-level=panic
root       888  1.0  1.1 616232 23652 ?        Ssl  12:23   0:00  \_ docker-containerd --config /var/run/docker/containerd/containerd.toml --log-level debug
```

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: aaa1392279ffe67a63581d2a43b3a3c7b0fc47b1
Component: engine
2018-07-09 15:38:08 +02:00
68bf9d2bfa Merge pull request #37390 from thaJeztah/update_cfssl_for_swarmkit
Update cloudflare/cfssl to 1.3.2
Upstream-commit: c8bda42d1632163c62f6a3d32969af2ba5463ab3
Component: engine
2018-07-09 09:10:25 +02:00
806ea23a1d Merge pull request #37409 from ctelfer/rm-libnet-error-wrapping
Fix faulty error type checking in removeNetwork()
Upstream-commit: 905811f366f28c1712626817f5fb086bd4072a78
Component: engine
2018-07-08 20:18:40 +02:00
a65c9b81e8 Fix typo on test.md
It said `TESTFLAGS='-test.run ^TestValidateIPAddress$' make test-unit`
runs `TestBuild` test, but actually runs `TestValidateIPAddress` test.

Signed-off-by: Donghwa Kim <shanytt@gmail.com>
Upstream-commit: 3048c3a7682919297d8d7d26897a59dc91b3be09
Component: engine
2018-07-08 18:22:21 +09:00
f4afbedc77 Ensure RUN instruction to run without Healthcheck
Before this commit Healthcheck run if HEALTHCHECK
instruction appears before RUN instruction.
By passing `withoutHealthcheck` to `copyRunConfig`,
always RUN instruction run without Healthcheck.

Fix: https://github.com/moby/moby/issues/37362

Signed-off-by: Yuichiro Kaneko <spiketeika@gmail.com>
Upstream-commit: 44e08d8a7d1249a1956018c6c3d3655642a4f273
Component: engine
2018-07-08 16:49:04 +09:00
f1b7597661 Get err type in removeNetworks() w/ errors.Cause()
Commit c0bc14e8 wrapped the return value of nw.Delete() with some extra
information.  However, this breaks the code in
containerAdaptor.removeNetworks() which ignores certain specific
libnetwork error return codes.  Said codes actually don't represent
errors, but just regular conditions to be expected in normal operation.
The removeNetworks() call checked for these errors by type assertions
which the errors.Wrap(err...) breaks.

This has a cascading effect, because controller.Remove() invokes
containerAdaptor.removeNetworks() and if the latter returns an error,
then Remove() fails to remove the container itself.  This is not
necessarily catastrophic since the container reaper apparently will
purge the container later, but it is clearly not the behavior we want.

Signed-off-by: Chris Telfer <ctelfer@docker.com>
Upstream-commit: 6225d1f15c5fd916c3e0ef3afe022f6cc14ac696
Component: engine
2018-07-07 18:18:53 -04:00
af3a05526e Merge pull request #37411 from tonistiigi/vendor-containerd
vendor: update containerd to b41633746
Upstream-commit: ae1160b8d8dd0b877bb58226852422c63b7210ce
Component: engine
2018-07-06 18:37:31 -07:00
3c2cc200c2 vendor: update containerd to b41633746
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: f0e61582664d16c5a608c3a742cc12b6b006bca6
Component: engine
2018-07-06 14:43:49 -07:00
9e7b5c6072 Merge pull request #37404 from runcom/no-acpi
Add /proc/acpi to masked paths
Upstream-commit: 86a41e4ef70ddeca610f2d0ed195a7834fc6bf4d
Component: engine
2018-07-06 22:40:08 +02:00
dcf345fe9b Bump libnetwork to 3ac297bc
Bump libnetwork to 3ac297bc7fd0afec9051bbb47024c9bc1d75bf5b in order to
get fix 0c3d9f00 which addresses a flaw that the scalable load balancing
code revealed.  Attempting to print sandbox IDs where the sandbox name
was too short results in a goroutine panic.  This can occur with
sandboxes with names of 1 or 2 characters in the previous code. But due
to naming updates in the scalable load balancing code, it could now
occur for networks whose name was 3 characters and at least one of the
integration tests employed such networks (named 'foo', 'bar' and 'baz').

This update also brings in several changes as well:
 * 6c7c6017 - Fix error handling about bridgeSetup
 * 5ed38221 - Optimize networkDB queue
 * cfa9afdb - ndots: produce error on negative numbers
 * 5586e226 - improve error message for invalid ndots number
 * 449672e5 - Allows to set generic knobs on the Sandbox
 * 6b4c4af7 - do not ignore user-provided "ndots:0" option
 * 843a0e42 - Adjust corner case for reconnect logic

Signed-off-by: Chris Telfer <ctelfer@docker.com>
Upstream-commit: 0e162d992394d9216f590176991d33ff48ef3389
Component: engine
2018-07-06 13:58:09 -04:00
c8c1e95dc9 Merge pull request #37394 from yongtang/07052018-ipcmode
Migrate some ipcmode tests to integration
Upstream-commit: aba2735e3fe66333ac1064bed3b476f30b1d1c00
Component: engine
2018-07-06 10:00:03 +02:00
be1844eeef Bump swarmkit to include task reaper fixes and more metrics.
This includes the following behavior-modifying PRs:

- docker/swarmkit#2673
- docker/swarmkit#2669
- docker/swarmkit#2675
- docker/swarmkit#2664

Signed-off-by: Ying Li <ying.li@docker.com>
Upstream-commit: b322705750cddef903a1097e65a46a6a86610d0a
Component: engine
2018-07-05 15:24:10 -07:00
ca577823d1 Merge pull request #37157 from debayande/even-more-names
Adds a few more names to the name generator.
Upstream-commit: 656036ce2cc949939e7eccc6d87d1e8be26e6890
Component: engine
2018-07-05 21:06:12 +02:00
d053f8aaa0 Merge pull request #37378 from cpuguy83/fix_bindmount_src_create_race
Fix bindmount autocreate race
Upstream-commit: cfc75f91ab172f7a202494880c188c7fd963997b
Component: engine
2018-07-05 20:36:49 +02:00
43a91b94e2 Merge pull request #37392 from thaJeztah/bump_fsnotify
update fsnotify to v1.4.7
Upstream-commit: e9c043517889accd19dd426d9f4aadaa18190896
Component: engine
2018-07-05 10:50:25 -07:00
b0a8f8763d Add /proc/acpi to masked paths
The deafult OCI linux spec in oci/defaults{_linux}.go in Docker/Moby
from 1.11 to current upstream master does not block /proc/acpi pathnames
allowing attackers to modify host's hardware like enabling/disabling
bluetooth or turning up/down keyboard brightness. SELinux prevents all
of this if enabled.

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
Upstream-commit: 569b9702a59804617e1cd3611fbbe953e4247b3e
Component: engine
2018-07-05 17:39:52 +02:00
8a5048081a Removed the "-i -t" arguments from the smoke test calling printf (these flags seem not really needed, and break jenkins builds with error "the input device is not a TTY")
Signed-off-by: Mickaël Remars <github@remars.com>
Upstream-commit: 2137e866b98d29f6a96df8a61c49f25a3ea2cb0d
Component: engine
2018-07-05 17:29:17 +02:00
aaa1925293 Merge pull request #37393 from mykeul/master
Added "--no-cache" to apk call to reduce alpine base image by 10-12% …
Upstream-commit: 06dee4cc27a1e5db75f2cdbcdcb7f762641b57d3
Component: engine
2018-07-05 15:06:21 +02:00
7340763295 Merge pull request #37388 from ianre657/patch-1
add vim-plug setting
Upstream-commit: 65dce935a66de6894b9877b63ce2276eb681ba81
Component: engine
2018-07-05 14:50:28 +02:00
cb25218045 Merge pull request #37380 from yui-knk/update_doc_Detect
Update documents of `Detect`
Upstream-commit: 8d56fa0bb780beb7b7116a8a17771179074408ea
Component: engine
2018-07-05 14:49:18 +02:00
d5f0e16922 Replaced "--update-cache" argument with "--no-cache" in apk call to reduce alpine base image by 10-12% (avoid useless indexes in /var/cache/apk)
Signed-off-by: Mickaël Remars <github@remars.com>
Upstream-commit: e72047a37586f5a929aaec0b8c73863d7209904b
Component: engine
2018-07-04 23:34:30 +02:00
bf53bc318d Migrate some ipcmode tests to integration
This fix migrates some ipcmode tests in integration-cli
to integration tests.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: e0403604e26868b1546a766ab0b40b6cb1677ee6
Component: engine
2018-07-04 16:32:18 +00:00
472b9e9903 Update cloudflare/cfssl to 1.3.2
Matching the version that is used in SwarmKit

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 7084487fdcfaf0fdb76a98757d49033c817c5978
Component: engine
2018-07-04 17:47:22 +02:00
086353aeec update fsnotify to v1.4.7
Fixes a possible deadlock on closing the watcher on kqueue

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 9f016c0fe1cd30381805fdb225854a36a806e961
Component: engine
2018-07-04 16:58:25 +02:00
a79f6da5b0 add vim-plug setting
this should work ( tried on my machine)

Signed-off-by: Ian Chen <ianre657@gmail.com>
Upstream-commit: a7652107189336f243e5c9a89b33a577df34fdd2
Component: engine
2018-07-04 15:54:19 +08:00
6f30c64548 Merge pull request #37381 from tiborvass/api-platforms-as-string-for-temp
api: Change Platform field back to string (temporary workaround)
Upstream-commit: b711437bbd8596312c962d4189e9ad4d2108c2dc
Component: engine
2018-07-03 17:54:42 -07:00
32dfa10dbf Merge pull request #37385 from tonistiigi/update-buildkit
vendor: update buildkit to 9acf51e491
Upstream-commit: 4b3df087a222fa34d771137b02348c51d9e107bc
Component: engine
2018-07-03 17:33:54 -07:00
6283fee6a2 api: Change Platform field back to string (temporary workaround)
This partially reverts https://github.com/moby/moby/pull/37350

Although specs.Platform is desirable in the API, there is more work
to be done on helper functions, namely containerd's platforms.Parse
that assumes the default platform of the Go runtime.

That prevents a client to use the recommended Parse function to
retrieve a specs.Platform object.

With this change, no parsing is expected from the client.

Signed-off-by: Tibor Vass <tibor@docker.com>
Upstream-commit: facad557440a0c955beb615495b8d0175f25e4e3
Component: engine
2018-07-03 22:33:42 +00:00
acd7279a5e vendor: update buildkit to 9acf51e491
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 6144f50e553cf268a4d27cbe774a67b6ab283423
Component: engine
2018-07-03 15:22:39 -07:00