Commit Graph

1855 Commits

Author SHA1 Message Date
a3ffabb772 Merge pull request #20843 from calavera/plugin_any_transport
Call plugins with custom transports.
Upstream-commit: c08b674d56c37782fc26382f4b756e0518e394cf
Component: engine
2016-03-04 11:59:32 -05:00
684bf382b9 Merge pull request #20872 from duglin/Issue20470
Optimize .dockerignore when there are exclusions
Upstream-commit: 9bc62e6031350d1db24e37cfa4983f719ab5e33b
Component: engine
2016-03-04 09:45:19 +01:00
e0a2d2cb2d Merge pull request #20730 from clnperez/sysinfo-match-ip-case
Match case for IP variables in sysinfo pkg
Upstream-commit: b7bc1ce1a4be4d309395303cdc573922a48bfd72
Component: engine
2016-03-03 08:48:57 -08:00
d784a76fa2 Optimize .dockerignore when there are exclusions
Closes #20470

Before this PR we used to scan the entire build context when there were
exclusions in the .dockerignore file (paths that started with !). Now we
only traverse into subdirs when one of the exclusions starts with that dir
path.

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 842b8d8784b132279003580eedd0e9c12b885815
Component: engine
2016-03-03 05:46:24 -08:00
8e7b2d5a4e Merge pull request #20896 from Microsoft/jjh/unit-pkg-integration
Windows CI: Turn off failing unit tests pkg\integration
Upstream-commit: 174959e8bfc56d73d1f4b2ee0247412f67c89a63
Component: engine
2016-03-03 10:41:21 +01:00
6c3e3e43c9 Merge pull request #20894 from Microsoft/jjh/unit-pkg-graphdb
Windows CI: Turn off failing unit tests pkg\graphdb
Upstream-commit: df1941bf0e70dd3f98c2aadcf56e0df5123b8382
Component: engine
2016-03-03 10:40:22 +01:00
0e8c018223 Windows CI: Turn off failing unit tests pkg\integration
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 5f2ba2b9ba5d1030dacb6c686d12c6a91c3c0612
Component: engine
2016-03-02 19:37:18 -08:00
e008756651 Windows CI: Turn off failing unit tests pkg\graphdb
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 9f5984d93fc4902d15904809015627b959bf11a1
Component: engine
2016-03-02 19:27:41 -08:00
2aa4a4fc21 Windows CI: Turn off failing unit test pkg\fileutils
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 3e78ad7be2c702a51c752965ba10d8fa9c6e9738
Component: engine
2016-03-02 19:05:33 -08:00
4a285f2027 Call plugins with custom transports.
Small refactor to be able to use custom transports
to call remote plugins.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 1a630234508bdb12d55425ceebdb0b6523a38578
Component: engine
2016-03-02 12:54:53 -05:00
5416da11e0 Merge pull request #20833 from Microsoft/testunit-archive
Windows CI: Unit Tests stop running failing archive test
Upstream-commit: b18f9cc29b8977bc003fd47aa35e8836345c301d
Component: engine
2016-03-02 08:53:11 +01:00
84f6ed6e39 Merge pull request #20842 from dongluochen/IPv6Support
Handle IPv6 entries in discovery
Upstream-commit: 266a75ac2219455d34aa6346596b936f42c20bcd
Component: engine
2016-03-01 21:03:37 -08:00
e470d00835 Use net.JoinHostPort to handle address format.
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
Upstream-commit: 7554e882dfe3a3eb9ec61457e20a42de528db725
Component: engine
2016-03-01 17:27:30 -08:00
78aa00dac4 Handle IPv6 entries.
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
Upstream-commit: f7c9214e29a81679916b953572173393d5e766e5
Component: engine
2016-03-01 16:56:12 -08:00
f7b441f49a Windows CI: Unit Tests stop running failing chrootarchive tests
Signed-off-by: Darren Stahl <darst@microsoft.com>
Upstream-commit: 7f6ef097369808d1d4eda52ff7bf0d76579741aa
Component: engine
2016-03-01 14:28:29 -08:00
fe36785c66 Windows CI: Unit Tests stop running failing archive test
Signed-off-by: Darren Stahl <darst@microsoft.com>
Upstream-commit: f9cfc4c38779ea8f443c79eeb8cc1b81e8e8a5e1
Component: engine
2016-03-01 13:27:44 -08:00
e740d4f911 Merge pull request #20587 from MHBauer/termfixes
do not turn post-processing on for linux-cgo terminals
Upstream-commit: bcc59fc95125e21ad59129189ff953b7086ab497
Component: engine
2016-03-01 11:37:26 -05:00
9fe49cb009 Match case for variables in sysinfo pkg
I noticied an inconsistency when reviewing docker/pull/20692.

Changing Ip to IP and Nf to NF.

More info: The golang folks recommend that you keep the initials consistent:
https://github.com/golang/go/wiki/CodeReviewComments#initialisms.

Signed-off-by: Christy Perez <christy@linux.vnet.ibm.com>
Upstream-commit: 5b3fc7aab25be908cab869dab5c0b2cb821d31dc
Component: engine
2016-03-01 10:37:05 -06:00
8066a67875 Merge pull request #20791 from Microsoft/jjh/testunit-pkgsymlink
Windows CI: Turning off pkg\symlink unit testing
Upstream-commit: dac18985fa5265c38a170b733d49a8ad31d2c645
Component: engine
2016-03-01 08:18:44 +01:00
6a88816da7 Merge pull request #20782 from estesp/new-parent-dir-ownership
Fix ownership of non-existing parent dir
Upstream-commit: 67b16c73818726d9818d0229fa6cdda3e5f698b0
Component: engine
2016-03-01 01:45:38 +01:00
d5b5c504a1 Windows CI: Turning off pkg\symlink unit testing
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: eaa1708e703427a47f28eb198942f18b9d7237d8
Component: engine
2016-02-29 13:10:50 -08:00
24e2f8a0e5 Merge pull request #20492 from WeiZhang555/export-no-privilege
Clean redundant error message for export
Upstream-commit: d878f512fd70928b28ca13629eb58befc14700f5
Component: engine
2016-02-29 21:14:28 +01:00
7d62a9ef68 Merge pull request #20780 from runcom/revert-sudo-user
Revert sudo user
Upstream-commit: a5d98b82ea641349640d07b2f62a047b94592a5e
Component: engine
2016-02-29 11:48:24 -08:00
569a4e8006 Merge pull request #20686 from clintonskitson/bugfix/plugin_desc_leak
Fix plugin file descriptor leaks
Upstream-commit: 29b2b0c22ba4a9c81002cd70e464ef0cfc577413
Component: engine
2016-02-29 10:44:36 -08:00
4b3ca35355 Merge pull request #20602 from twistlock/20508_authz_plugin_corrupt_body
Fix #20508 - Authz plugin enabled with large text/JSON POST payload corrupts body
Upstream-commit: abbb16d7abd7150a9226252f2544326930ea2baf
Component: engine
2016-02-29 10:43:02 -05:00
848fd14888 Fix ownership of non-existing parent dir
During "COPY" or other tar unpack operations, a target/destination
parent dir might not exist and should be created with ownership of the
root in the right context (including remapped root when user namespaces
are enabled)

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Upstream-commit: 7a61b9ae425e5c100da2bb32b929031c6302b3fb
Component: engine
2016-02-29 09:14:23 -05:00
c762170458 Revert "resolve the config file from the sudo user"
This reverts commit afde6450ee7bd4a43765fdc0a9799b411276d9e4.

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
Upstream-commit: 863b5716173db320ddc03847a639964f495a7953
Component: engine
2016-02-29 13:51:43 +01:00
79c9ac5435 Merge pull request #20706 from calavera/remove_concurrent_access_to_stdtypes
Make stdcopy.StdWriter thread safe.
Upstream-commit: ec268be52ee3a2fab5c792ecf836f109595712ae
Component: engine
2016-02-27 21:14:09 -05:00
fac52dba98 Fixes plugin file descriptor leak on plugin discovery
Signed-off-by: Clinton Kitson <clintonskitson@gmail.com>
Upstream-commit: 799ae78b7efa9ffb8e142a0a211325cca59987be
Component: engine
2016-02-26 19:43:50 -08:00
84d241709b Make stdcopy.stdWriter goroutine safe.
Stop using global variables as prefixes to inject the writer header.
That can cause issues when two writers set the length of the buffer in
the same header concurrently.

Stop Writing to the internal buffer twice for each write. This could
mess up with the ordering information is written.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 443a5c20216b5331b1bb57796140c0178ca44b7d
Component: engine
2016-02-26 16:51:18 -05:00
8491fb072b pkg: idtools: fix subid files parsing
Since Docker is already skipping newlines in /etc/sub{uid,gid},
this patch skips commented out lines - otherwise Docker fails to start.
Add unit test also.

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
Upstream-commit: bf04d68db2b808a40fa24ac2bfa86c8af22d5f11
Component: engine
2016-02-26 15:42:05 +01:00
623b2b65cf Merge pull request #20263 from Microsoft/jjh/testunit-fileutils
Windows CI: Fixes panic in test-unit for FileUtils
Upstream-commit: 6c35350baba816f99bd8236b4b463bbb8d61e25d
Component: engine
2016-02-25 17:35:32 -08:00
d0fa8c5e37 Merge pull request #20572 from runcom/sudo-user
resolve the config file from the sudo user
Upstream-commit: 61d24e769d9f7a075f6881ba8b4523d5db9dcd6d
Component: engine
2016-02-25 16:05:25 +01:00
05479dd564 Fix #20508 - Authz plugin enabled with large text/JSON POST payload corrupts body
Based on the discussion, we have changed the following:

1. Send body only if content-type is application/json (based on the
Docker official daemon REST specification, this is the provided for all
APIs that requires authorization.

2. Correctly verify that the msg body is smaller than max cap (this was
the actual bug). Fix includes UT.

3. Minor: Check content length > 0 (it was -1 for load, altough an
attacker can still modify this)

Signed-off-by: Liron Levin <liron@twistlock.com>
Upstream-commit: ca5c2abecfd12ad22b75c69e0debde7b625c2735
Component: engine
2016-02-25 08:11:55 +02:00
1ca6d4e7c1 Close resp body on plugin call error
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 93ad9c31fce375b29606ea347df28c1205e7cb41
Component: engine
2016-02-24 20:09:51 -05:00
828abfa863 add file poller panic fix from 1.10.2
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: f9524a4d24d6135ae1777738390e1f6a590a7a1c
Component: engine
2016-02-24 10:17:29 -05:00
008e491a8c resolve the config file from the sudo user
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
Upstream-commit: afde6450ee7bd4a43765fdc0a9799b411276d9e4
Component: engine
2016-02-24 15:41:00 +01:00
0a8b8e629c Revert "use pubsub instead of filenotify to follow json logs"
This reverts commit b1594c59f5e0d1ac898eacde8d91b1ba33c2b626.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 91fdfdd53722179b21b80b9dfbe8bc2e09d0a7b1
Component: engine
2016-02-23 21:43:52 -05:00
165355ea85 Revert "pkg: remove unused filenotify"
This reverts commit ee99b5f2e96aafa982487aadbb78478898ae0c71.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: f78091897a9926399224886788c373b4ff9d14bf
Component: engine
2016-02-23 21:43:46 -05:00
0ef64b8897 do not turn post-processing on for linux-cgo term
- fixes #15373
 - remove set OPOST output flag for termios
 - remove latent os.Exit call

Signed-off-by: Morgan Bauer <mbauer@us.ibm.com>
Upstream-commit: 67629c8b52f95218c2ef4ff781b6dfdcd8e88ba9
Component: engine
2016-02-23 14:14:58 -08:00
3a8090633a Windows CI: Fixes panic in test-unit for FileUtils
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: b368a9f9b792ff75cbc5ee5a357b342b99a11e04
Component: engine
2016-02-23 13:31:45 -08:00
f62b97e499 Fix some typos in comments and strings
Most of them were found and fixed by codespell.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
Upstream-commit: 2eee613326fb59fd168849618d14a9054a40f9f5
Component: engine
2016-02-22 20:27:15 +01:00
b1aa8c8912 Clean redundant error message for export
When execute `docker export -o path xxx` and path is a directory docker
has no privilege to write to, daemon will print lots of error logs that
most of them are duplicated and redundant.

This will remove unnecessary error logs and print only once.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 439433099e261d504561d834839fcb936fb7ea95
Component: engine
2016-02-19 18:50:11 +08:00
4456b512b3 Merge pull request #20292 from Microsoft/jjh/testunit-pkgarchivestep2
Windows CI: test-unit on pkg\archive part 2
Upstream-commit: aae454cb520cb36e5b4b36f7d71a6297c6ffc3c2
Component: engine
2016-02-18 12:12:09 -05:00
9c01cfa3e9 Merge pull request #20408 from cpuguy83/use_pool_for_pubsub_wg
Use pool for pubsub `Publish`'s waitgroups
Upstream-commit: 9a81f206b3f951e9e19e642b070fcab393fa3318
Component: engine
2016-02-17 14:46:13 -08:00
c68f4a42c4 Merge pull request #20260 from Microsoft/jjh/testunit-pkggitutils
Windows CI: Unit tests - port pkg\gitutils
Upstream-commit: 647d3266eab1bf184f6c880c972a75c1b80a32cc
Component: engine
2016-02-17 13:50:17 -08:00
7aa41cb67d Use pool for pubsub Publish's waitgroups
benchmark             old ns/op      new ns/op      delta
BenchmarkPubSub-8     1036494796     1032443513     -0.39%

benchmark             old allocs     new allocs     delta
BenchmarkPubSub-8     2467           1441           -41.59%

benchmark             old bytes     new bytes     delta
BenchmarkPubSub-8     212216        187792        -11.51%

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 58d98f82888345a49f2e7660a0a5b35a5da891f5
Component: engine
2016-02-17 14:36:57 -05:00
54e25a7e3f pkg: remove unused filenotify
pkg/filenotify isn't used anymore and it causes problems with
hack/vendor.sh (nothing uses it, so hack/vendor.sh will remove the
vendored code).

Signed-off-by: Aleksa Sarai <asarai@suse.com>
Upstream-commit: ee99b5f2e96aafa982487aadbb78478898ae0c71
Component: engine
2016-02-18 00:11:43 +11:00
83d138a180 Merge pull request #20366 from LK4D4/socks_proxy
Add support for forwarding Docker client through SOCKS proxy
Upstream-commit: 5c78515430860ad822e016cc5cd5d5ff3dd6a21c
Component: engine
2016-02-16 22:29:49 -08:00
f663556077 Merge pull request #19498 from mountkin/refactor-jsonfilelog-reader
use pubsub instead of filenotify to follow json logs
Upstream-commit: 8545fdc6ddd7010a4134062cf99444e586c3c99e
Component: engine
2016-02-16 13:55:48 -08:00