Commit graph

24487 commits

Author SHA1 Message Date
Vincent Demeester
fb48bf518b
Move some container related methods and structs to smaller files
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-05-24 21:31:15 +02:00
John Starks
8fc825364a pkg/integration: Port tests to Windows
Signed-off-by: John Starks <jostarks@microsoft.com>
2016-05-24 12:12:48 -07:00
Sebastiaan van Stijn
48a53d2e8c Merge pull request #22935 from thaJeztah/add-justin-to-maintainers
Add Justin Cormack to maintainers
2016-05-24 20:23:52 +02:00
Derek McGowan
5cc0824730 Remove unused mounted function in overlay
The mount check is now done by the FSChecker. This function is no longer needed and shouldn't be called.

Signed-off-by: Derek McGowan <derek@mcgstyle.net> (github: dmcgowan)
2016-05-24 11:02:07 -07:00
Alexander Morozov
38217d4353 Merge pull request #22932 from chenchun/fix_build
Fix building image  error if bridge network is disabled
2016-05-24 10:33:34 -07:00
Vincent Demeester
f0d6fd93a2 Merge pull request #22756 from wangxing1517/fix_docs_dockerd.md
Fix incorrectly named "ip-mask" and "api-cors-headers" options
2016-05-24 18:21:52 +02:00
Sebastiaan van Stijn
f10a222de1 Merge pull request #22941 from AkihiroSuda/fix22940
Fix a race in cmd/dockerd/hack.TestHeaderOverrideHack
2016-05-24 18:13:44 +02:00
Sebastiaan van Stijn
7faa2a40bc Merge pull request #22264 from aaronlehmann/updated-image-spec
Update image specification for content-addressability changes
2016-05-24 18:06:52 +02:00
Vincent Demeester
1dc87a6f9f Merge pull request #22945 from albers/completion-daemon-events
bash completion for daemon events
2016-05-24 17:30:18 +02:00
Harald Albers
cc6a1b8bb3 bash completion for daemon events
Signed-off-by: Harald Albers <github@albersweb.de>
2016-05-24 17:19:03 +02:00
Vincent Demeester
0fb6190243
Fix escape-keys by preserving input if invalid
Currently, using a custom detach key with an invalid sequence, eats a
part of the sequence, making it weird and difficult to enter some key
sequence.

This fixes by keeping the input read when trying to see if it's the key
sequence or not, and "writing" then is the key sequence is not the right
one, preserving the initial input.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-05-24 17:14:48 +02:00
Vincent Demeester
ce07eac570 Merge pull request #22906 from nshalman/patch-1
Clarification about 'docker build --build-arg'
2016-05-24 15:33:27 +02:00
Nahum Shalman
fd7d99ed28 Clarification about 'docker build --build-arg'
See #22860

Signed-off-by: Nahum Shalman <nshalman@omniti.com>
2016-05-24 09:25:11 -04:00
Vincent Demeester
6a385a0022 Merge pull request #22900 from AkihiroSuda/fix22020
update docs/reference/commandline/cp.md
2016-05-24 14:06:02 +02:00
Akihiro Suda
1670914b8a Fix a race in cmd/dockerd/hack.TestHeaderOverrideHack
Fix #22940

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
2016-05-24 11:29:55 +00:00
Akihiro Suda
cb1635c9cf update docs/reference/commandline/cp.md
Close #22020

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
2016-05-24 11:09:38 +00:00
Sebastiaan van Stijn
e427e4b108 Add Justin Cormack to maintainers
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-05-24 11:09:39 +02:00
Vincent Demeester
636c276f67
Add Unit test to daemon.SearchRegistryForImages…
… and refactor a little bit some daemon on the way.

- Move `SearchRegistryForImages` to a new file (`daemon/search.go`) as
  `daemon.go` is getting pretty big.
- `registry.Service` is now an interface (allowing us to decouple it a
  little bit and thus unit test easily).
- Add some unit test for `SearchRegistryForImages`.
- Use UniqueExactMatch for search filters
- And use empty restore id for now in client.ContainerStart.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-05-24 11:07:11 +02:00
Vincent Demeester
d76d38c7d0 Merge pull request #22590 from yongtang/22463-docker-daemon-events
Emit events for docker daemon
2016-05-24 11:05:39 +02:00
Vincent Demeester
5812b6927c
Vendor engine-api updates
Adds UniqueExactMatch method to filters along other changes.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-05-24 11:02:19 +02:00
Chun Chen
a8d013495c Fix building image error if bridge network is disabled
Signed-off-by: Chun Chen <ramichen@tencent.com>
2016-05-24 16:20:26 +08:00
Vincent Demeester
bf7bae9662 Merge pull request #22928 from friism/patch-3
remove duplicated text
2016-05-24 08:38:40 +02:00
Alexander Morozov
d7dfe9103b Merge pull request #22541 from crosbymichael/graph-restore
Implement graph driver restore on reboot
2016-05-23 22:57:23 -07:00
Justin Cormack
a83cedddc6 Enable seccomp on ppc64le
In order to do this, allow the socketcall syscall in the default
seccomp profile. This is a multiplexing syscall for the socket
operations, which is becoming obsolete gradually, but it is used
in some architectures. libseccomp has special handling for it for
x86 where it is common, so we did not need it in the profile,
but does not have any handling for ppc64le. It turns out that the
Debian images we use for tests do use the socketcall, while the
newer images such as Ubuntu 16.04 do not. Enabling this does no
harm as we allow all the socket operations anyway, and we allow
the similar ipc call for similar reasons already.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
2016-05-23 22:35:55 -07:00
Tõnis Tiigi
a5aba7752a Merge pull request #22926 from justincormack/seccomp-test
Fix error channel size in seccomp test
2016-05-23 22:28:24 -07:00
Michael Friis
5271a69411 remove duplicated text
Signed-off-by: Michael Friis <friism@gmail.com>
2016-05-23 19:01:30 -07:00
Yong Tang
62014aaf9a Add filter for events emitted by docker daemon
This fix tries to cover the issue raised in #22463 by adding
filter for events emitted by docker daemon so that user could
utilize filter to receive events of interest.

Documentations have been updated for this fix.

Additional tests have been added to cover the changes in this fix.

This fix fixes #22463.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2016-05-23 19:00:47 -07:00
Yong Tang
382c152a73 Emit events for docker daemon
This fix tries to cover the issue raised in #22463 by emitting
events for docker daemon so that user could be notified by
scenarios like config reload, etc.

This fix adds the `daemon reload`, and events for docker daemon.

Additional tests have been added to cover the changes in this fix.

This fix fixes #22463.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2016-05-23 19:00:47 -07:00
Doug Davis
94d0571304 Fix flaky TestApiStatsNetworkStats test
It appears that on some systems apparmor gets in the way of libc.so.6
shared library being loaded - which means the ping fails.

To get around this if we run ping under `/lib64/ld-linux-x86-64.so.2`
then it works.  So we only do this for linux and only if the first attempt
fails. If this 2nd attempt fails then we'll show the original error to
the user for debugging.

Also s/Output/CombinedOutput/ to help debugging in the future. It didn't
show the real error msg.

Signed-off-by: Doug Davis <dug@us.ibm.com>
2016-05-23 19:00:19 -07:00
Justin Cormack
3598f2e331 Fix error channel size in seccomp test
This was not changed when the additional tests were added.
It may be the reason for occasional test failures.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
2016-05-23 18:14:55 -07:00
Brian Goff
9bc6c4ef80 Merge pull request #22919 from LK4D4/carry_22754
cli: remove unnecessary initErr type
2016-05-23 20:21:08 -04:00
Michael Crosby
8bb4d31b10 Remove mountedLayer Mount and Unmount
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 16:52:58 -07:00
Amit Krishnan
86d8758e2b Get the Docker Engine to build clean on Solaris
Signed-off-by: Amit Krishnan <krish.amit@gmail.com>
2016-05-23 16:37:12 -07:00
Michael Crosby
36a82c2032 Fix overlay use of rootdir and defer
Check for the rootDir first because the mergeDir may not exist if root
is present.

Also fix unmounting in the defer to make sure it does not have a
refcount.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 16:03:40 -07:00
Michael Crosby
4bac8bce98 Add windows graph driver ref counter
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 16:03:40 -07:00
Michael Crosby
e19499710e Remove ref counting from layer store
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 15:57:23 -07:00
Michael Crosby
5b6b8df0c1 Add reference counting to aufs
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 15:57:23 -07:00
Michael Crosby
1ba05cdb6a Add fast path for fsmagic supported drivers
For things that we can check if they are mounted by using their fsmagic
we should use that and for others do it the slow way.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 15:57:23 -07:00
Michael Crosby
31e903b0e1 Remove restart test
This test is not applicable anymore now that containers are not stopped
when the daemon is restored.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 15:57:23 -07:00
Michael Crosby
290be017c5 Remove overlay pathCache
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 15:57:23 -07:00
Michael Crosby
009ee16bef Restore ref count
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-05-23 15:57:23 -07:00
Doug Davis
ac043c7db6 Fix docker import tests
For me when I run the test I see:
```
Downloading from http://nourl/bad
Importing    283 B
Untar re-exec error: exit status 1: output: unexpected EOF
```
and nothing about "dial tcp" so it appears that the output is
system dependent and therefore we can't really check it. I think
checking for non-zero exit code is sufficient so I'm removing this
string check.

Signed-off-by: Doug Davis <dug@us.ibm.com>
2016-05-23 15:34:40 -07:00
muge
b65e57bed5 cli: remove unnecessary initErr type
Signed-off-by: ZhangHang <stevezhang2014@gmail.com>
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2016-05-23 13:04:10 -07:00
Sebastiaan van Stijn
91bc4cca58 Merge pull request #22875 from Microsoft/jjh/nativeconsoleon
Windows: Turn on native console by default
2016-05-23 21:19:54 +02:00
Sebastiaan van Stijn
2cd8b876ad Merge pull request #22665 from isubuz/20788-doc-valid-tag-name
docs: add valid chars in image name and tag
2016-05-23 20:45:27 +02:00
Tonis Tiigi
bd2b3d363f Release memoryStore locks before filter/apply
Rework memoryStore so that filters and apply run
on a cloned list of containers after the lock has
been released. This avoids possible deadlocks when
these filter/apply callbacks take locks for a
container.

Fixes #22732

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2016-05-23 11:45:04 -07:00
Alexander Morozov
9f1a121259 Merge pull request #22774 from Microsoft/jjh/client
Windows: Daemon default to Hyper-V containers on client
2016-05-23 11:29:50 -07:00
Alexander Morozov
3ab9049be3 Merge pull request #22856 from thaJeztah/dont-warn-when-net-none
Suppress "IPv4 forwarding" warning for --net=none
2016-05-23 11:11:21 -07:00
Alexander Morozov
0ac881b705 Merge pull request #22873 from jstarks/fix_bs_del
Windows: Work around Windows BS/DEL behavior
2016-05-23 11:10:33 -07:00
Tibor Vass
5f95750ab4 Merge pull request #22878 from vdemeester/better-default-context
Rework usage of context.Context in api/client
2016-05-23 13:43:08 -04:00