Commit Graph

2145 Commits

Author SHA1 Message Date
fd88171dba Merge pull request #27705 from dmcgowan/fix-27298
Ensure opaque directory permissions respected
Upstream-commit: bcdce2a6b0d52a18b4eb4a2cb7710b248be88e51
Component: engine
2016-11-02 10:13:30 +01:00
07a831dfc2 Fix logrus formatting
This fix tries to fix logrus formatting by removing `f` from
`logrus.[Error|Warn|Debug|Fatal|Panic|Info]f` when formatting string
is not present.

Fixed issue #23459

Signed-off-by: Daehyeok Mun <daehyeok@gmail.com>
Upstream-commit: fa710e504b0e3e51d4031790c18621b02dcd2600
Component: engine
2016-10-31 22:05:01 -06: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
8d3cacc3b2 Merge pull request #27804 from anusha-ragunathan/blacklist-authz
Blacklist authz plugins that failed.
Upstream-commit: 406c19f0961c5987c8ce3f980b6fbf36e845f9c4
Component: engine
2016-10-28 15:06:20 -07:00
1599ca6ae6 Ensure opaque directory permissions respected
When converting an opaque directory always keep the original
directory tar entry to ensure directory is created with correct
permissions on restore.

Closes #27298

Signed-off-by: Derek McGowan <derek@mcgstyle.net> (github: dmcgowan)
Upstream-commit: daa70195171d798cdfb6c4033b33a06a8f7ebe6c
Component: engine
2016-10-28 13:13:10 -07:00
78119ce904 Update authz plugin list on failure.
When daemon fails to load an authz plugin, it should be removed from
the plugin list. Else the plugin is retried on every request and
response, resulting in undesired behavior (eg. daemon panic)

Signed-off-by: Anusha Ragunathan <anusha@docker.com>
Upstream-commit: fae904af02a184833d2cd5ce9fdd61a4083707c7
Component: engine
2016-10-28 11:16:06 -07:00
55b1731260 stdcopy: remove logrus debug messages; makes it easier to vendor without the dependency.
Signed-off-by: Erik Hollensbe <github@hollensbe.org>
Upstream-commit: c4be1b117f8226a7aad792c5be315d093adf19cf
Component: engine
2016-10-26 16:29:37 -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
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
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
ccce8d9194 mkdirall on the PID file path
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 745f3ece53cc037030c0618f75f2cd551baa1b6c
Component: engine
2016-10-25 09:11:20 -07:00
accc5bf3d7 Merge pull request #27609 from tonistiigi/fix-chroot-shared-parent
chroot: remount everything as private in new mntns
Upstream-commit: 87ae571fed06193a319c6776bfd19cc64067e511
Component: engine
2016-10-21 14:40:40 -07:00
d87cb9a48f Merge pull request #27522 from vieux/data_race_plugins
prevent data race in pkg/plugins
Upstream-commit: d0e6dae233e0f66aa969a2ac3d28685c365cdf6c
Component: engine
2016-10-21 14:19:48 -07:00
f449f9bc63 prevent data race in pkg/plugins
Signed-off-by: Victor Vieux <vieux@docker.com>
Upstream-commit: f7af80860cf99ce808834260ac190a2a88bc24e2
Component: engine
2016-10-21 13:28:13 -07:00
6c158febcb Merge pull request #27613 from stevvooe/archive-package-cleanup
pkg/archive: remove unnecessary Archive and Reader type
Upstream-commit: bc52939b0455116ab8e0da67869ec81c1a1c3e2c
Component: engine
2016-10-20 20:56:23 -07:00
fe1dce6a91 pkg/archive: remove unnecessary Archive and Reader type
The `archive` package defines aliases for `io.ReadCloser` and
`io.Reader`. These don't seem to provide an benefit other than type
decoration. Per this change, several unnecessary type cases were
removed.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: aa2cc18745cbe0231c33782f0fa764f657e3fb88
Component: engine
2016-10-20 19:31:24 -07:00
3b85a5f98c Merge pull request #27606 from stevvooe/no-pool-pointer
pkg/pool: no need for double pointer for sync.Pool
Upstream-commit: 2e742b022190dbd0d2897b9c2bd3da2f045d708e
Component: engine
2016-10-20 17:03:41 -07:00
f8d146b07d chroot: let root be cleaned up by kernel
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 70dfea63ba2a8a6d8b367420039aeb6a1759c240
Component: engine
2016-10-20 15:50:46 -07:00
253426676c chroot: remount everything as private in new mntns
If parent of the destination path is shared, this
path will be unmounted from the parent ns even if
the path itself is private.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: b511d1f0cabd32ca30c87fa1bbc7ecac283dab39
Component: engine
2016-10-20 15:29:23 -07:00
0f8d925c2d pkg/pool: no need for double pointer for sync.Pool
Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: 836f347cb04f28ee80bb5d877c5599f91ed1ef60
Component: engine
2016-10-20 15:27:38 -07:00
56af301200 Merge pull request #27287 from mavenugo/pluginv2-sk2
Allow multiple handlers to support network plugins in swarm-mode 
Upstream-commit: 2c620d0aa24c5f774a9115449a86b158b005bba8
Component: engine
2016-10-20 13:43:04 -07:00
8fb804fc58 Fix the typo of URLs
Signed-off-by: YuPengZTE <yu.peng36@zte.com.cn>
Upstream-commit: fa378413f88054d0a336d675e7280930ddc86cb2
Component: engine
2016-10-19 17:46:27 +08:00
3643ef102a Merge pull request #27267 from ezrasilvera/plugin_fix
Call the AuthZRes function also when the daemon  returns error
Upstream-commit: 194f04bbbe5b4de06235bf56b8842cadac0294dc
Component: engine
2016-10-18 21:53:43 -07:00
1050d22554 Allow plugins to have multiple handlers
Currently the plugins pkg allows a single handler. This assumption
breaks down if there are mutiple listeners to a plugin of a certain
Manifest such as NetworkDriver or IpamDriver when swarm-mode is enabled.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 5e9c78aeaf1d88000921190b88a1d91d6261208c
Component: engine
2016-10-17 09:00:17 -07:00
6d715e3038 Fix broken JSON support in cli/command/formatter
How to test:

    $ docker ps --format '{{json .}}'
    $ docker network ls --format '{{json .}}'
    $ docker volume ls --format '{{json .}}'

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Upstream-commit: 3a32b587922eca87d1ab23689f407b75a8603ccb
Component: engine
2016-10-17 08:07:17 +00:00
e063aa0187 Merge pull request #27366 from morelena/use_contains
all: use strings.Contains instead Index
Upstream-commit: 21a79b503a5c1331d0c000d26179a55fc235b021
Component: engine
2016-10-13 18:44:30 -07:00
70177b59a1 all: use strings.Contains instead Index
Signed-off-by: Elena Morozova <lelenanam@gmail.com>
Upstream-commit: a37027f6bdcb2f035fcccd99c6c6064934623a04
Component: engine
2016-10-13 15:55:41 -07:00
b1d937a58f Merge pull request #27365 from morelena/remove_nil_check
all: remove nil check for slices
Upstream-commit: 245bd4c3d2594fae3fd5099f29eef528a4c4accd
Component: engine
2016-10-13 15:27:37 -07:00
17191e6609 all: remove nil check for slices
Signed-off-by: Elena Morozova <lelenanam@gmail.com>
Upstream-commit: ace53bbe65d1384893027d046a5d4eae83bd60af
Component: engine
2016-10-13 13:55:38 -07:00
4b9781e130 all: replace loop with single append
Signed-off-by: Elena Morozova <lelenanam@gmail.com>
Upstream-commit: 64238fef8c7b739a2ae5648386cf594eb3a162e5
Component: engine
2016-10-13 13:31:52 -07:00
1f94129ec0 Merge pull request #27293 from anusha-ragunathan/use-pluginv2-authz
Make authz use pluginv2
Upstream-commit: 8658748ef716e43a5f6d834825d818012ed6e2c4
Component: engine
2016-10-13 00:28:43 +02:00
2a20bc38c9 pkg/authorization: make it goroutine-safe
It was racy on config reload

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: a616cf3b88ee264b9a565dc0c25e583444ba64e2
Component: engine
2016-10-11 16:31:45 -07:00
d71f1080b9 Make authorization plugins use pluginv2.
Signed-off-by: Anusha Ragunathan <anusha@docker.com>
Upstream-commit: c5393ee147e981ded8fdf12c8da790abd1130175
Component: engine
2016-10-11 13:09:28 -07:00
8544599d78 Call the AuthZRes function also when the daemon returns error
Signed-off-by: Ezra Silvera <ezra@il.ibm.com>
Upstream-commit: 5a8ff4025408ed7a30a829008edf509c02f7a258
Component: engine
2016-10-11 09:53:30 +03:00
f1f88179ba Reduce TestRunCommandWithTimeoutKilled flakiness
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 797f630d2e3c9180848b1adb7fd6fa879f284165
Component: engine
2016-10-10 17:31:37 -07:00
e0f35ce34e pkg/archive/changes_posix_test.go: un-comment code line "defer os.RemoveAll(src)"
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 6514299fa9b716adbb04e67be583a335cd123398
Component: engine
2016-10-10 05:23:24 -04:00
9ad2ffa17a Merge pull request #27160 from mlaventure/update-containerd
Update containerd and runc
Upstream-commit: 5ee2c2a6475056f55327ce77b61677499a9e3fa8
Component: engine
2016-10-06 19:36:31 +02:00
6e5d016ba6 Update containerd and runc
containerd: 837e8c5e1cad013ed57f5c2090c8591c10cbbdae
runc: 02f8fa7863dd3f82909a73e2061897828460d52f

Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
Upstream-commit: 7e12c3bb99381f117be73e05c187be6ce44280b9
Component: engine
2016-10-05 14:47:15 -07:00
afe0671bd1 Force input stream ANSI emulation for ConsoleZ
This performs a similar check to the `"ConEmuANSI"` check that was recently
added to enable arrow keys navigation in docker container terminals.

Signed-off-by: Josh Wilson <josh.wilson@fivestars.com>
Upstream-commit: c0a5772668c5a2cb6d17a6b5907fc3eb08d18cc7
Component: engine
2016-10-05 12:42:48 -07:00
7ec53d01f4 Add plugingetter to pkg.
plugingetter is indepedent of docker/docker packages, so it can be
moved to pkg. This is also necessary for authorization plugins (part of
pkg) to use pluginv2. The original path at plugin/getter will be
eventually removed, when external repos (eg. libnetwork) update their
import paths.

Signed-off-by: Anusha Ragunathan <anusha@docker.com>
Upstream-commit: d599d53db27f4a24b18f51464c39707eae383c7e
Component: engine
2016-10-04 12:03:29 -07:00
5f25d3f4ea Fix error reporting in CopyFileWithTar
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 57e12037ac8f8eb48cc05979c3030853d011dfea
Component: engine
2016-09-30 11:46:37 -07:00
c15d8c9103 Fix apparmor profile installation
Fixes #26823

Fixes an issue where apparmor was not loaded into the kernel, because
apparmor_parser was being called incorrectly.

Signed-off-by: Christopher Jones <tophj@linux.vnet.ibm.com>
Upstream-commit: 1a702111c61076e14f0e7ae688d0102128233daf
Component: engine
2016-09-29 18:47:20 -05:00
711fedae4a Return pipeline errors correctly.
To use a deferred func to overwrite the returned error requires using
the 'named' error. So reuse err, instead of pipelineError. Also, the old
pipelineError will never be nil, since its executed before the error can
be set.

Signed-off-by: Anusha Ragunathan <anusha@docker.com>
Upstream-commit: af2e2562494a11ee8e6ede58a29cc250935e74c4
Component: engine
2016-09-23 13:09:56 -07:00
f07146ebf8 Make graphdrivers work with pluginv2.
As part of making graphdrivers support pluginv2, a PluginGetter
interface was necessary for cleaner separation and avoiding import
cycles.

This commit creates a PluginGetter interface and makes pluginStore
implement it. Then the pluginStore object is created in the daemon
(rather than by the plugin manager) and passed to plugin init as
well as to the different subsystems (eg. graphdrivers, volumedrivers).
A side effect of this change was that some code was moved out of
experimental. This is good, since plugin support will be stable soon.

Signed-off-by: Anusha Ragunathan <anusha@docker.com>
Upstream-commit: fefea805e930a67fb6327f8e59415932861358cb
Component: engine
2016-09-20 08:49:48 -07:00
90dfc08974 Merge pull request #26436 from stevvooe/remove-transport-package
client: remove transport package 
Upstream-commit: 7a86930c7452e19ee72557bb8264e81378ccfbb5
Component: engine
2016-09-20 16:43:56 +02:00
4cd6f89f27 Revert "Add default timeout to pkg/plugins/client"
This reverts commit 0699b00d26a60f4a8447572b34c4aad1ce73d2e1.

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
Upstream-commit: 5c35bfed3f4823e205c5d5b171f23972ff8b3de0
Component: engine
2016-09-20 10:01:03 +02:00
a54b053e2e Merge pull request #26662 from WeiZhang555/fix-flaky-unit-test
Fix flaky unit test
Upstream-commit: 56952e2159f464e2b3a038b81b8d11be45cee308
Component: engine
2016-09-17 18:32:11 -07:00
5049c43226 Merge pull request #25737 from Microsoft/jjh-statistics
Windows: Add support for docker stats
Upstream-commit: 4a0419f536ce3a7b1eade67440cfc84d6e486caf
Component: engine
2016-09-17 09:31:24 -07:00
1dc2c82ca8 Fix flaky unit test
Fix flaky test `TestHTTPTimeout` caused by precision problem.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: bc5768733db79874d8918e8499df01d68cae2d6e
Component: engine
2016-09-17 19:40:58 +08:00
7342ae40e2 Windows: stats support
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 340e5233b2fb95981ddea610c1667134ed3b2376
Component: engine
2016-09-16 11:56:15 -07:00