Commit Graph

1453 Commits

Author SHA1 Message Date
472d3d817f Merge pull request #15922 from unclejack/lower_reset_timeout_bufreader
pkg/ioutils: lower bufReader reset timeout
Upstream-commit: 3bd8016259711c951bd9b2023c176f7825c5d56c
Component: engine
2015-08-31 18:43:45 +02:00
4e8cadcb64 Merge pull request #15489 from aaronlehmann/pull-updates
Show pull progress in terminal for inflight pull requests
Upstream-commit: 84614fdae00fbdb66b5ae6de1c8246c470ef4f5c
Component: engine
2015-08-31 09:37:33 -07:00
7981f6d0c0 pkg/ioutils: lower bufReader reset timeout
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Upstream-commit: f9df813a992505ba2b37fad843ab943347d3ef11
Component: engine
2015-08-28 23:13:02 +03:00
ff33b3e79f More httputil tests for the docker header
follow-on to #15911

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 5e540bdc132669dfb8c13ae2796104a03aca6287
Component: engine
2015-08-28 12:16:37 -07:00
7ee1aa79e9 Make the broadcaster write messages to the observers in the same units they were written to the broadcaster
This means the writing to a WriteFlusher will flush in the same places
as it would if the broadcaster wasn't sitting in front of it.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 317a5462e428fab6248fe3b028822250c8c9ff7f
Component: engine
2015-08-28 10:09:00 -07:00
aa8f27039b Merge pull request #15902 from SvenDowideit/add-more-tests-for-parsehost
Exploring the parsehost using unit tests
Upstream-commit: 50bcf17c39e96c1032eac9e8a450533f84129220
Component: engine
2015-08-28 09:14:35 -07:00
ed84a12688 Fix server header parsing.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 243f98ff6de7aa16319be25c57ef1d910dfb6770
Component: engine
2015-08-28 11:06:24 -04:00
51511f9e16 unit test refactor in pkg/httputils as suggested by vdemeester; using pattern if x := …; x == nil {}
Signed-off-by: Kristina Zabunova <triara.xiii@gmail.com>
(cherry picked from commit c3f1b2a5bd4a4330bcbad401c316af90925b99ad)
Upstream-commit: f753f6d597efb218d4b5786b9a4f09b6e73b48bc
Component: engine
2015-08-28 10:41:19 -04:00
208ac7a049 Increased test coverage of httputils to 70 %
Signed-off-by: Kristina Zabunova <triara.xiii@gmail.com>
(cherry picked from commit d71817464e859cd323d6cdaf4dec5a9dd530f57e)
Upstream-commit: b3f999e86331b3c19572a88b5e123ea961ac54fb
Component: engine
2015-08-28 10:41:19 -04:00
d04df77c91 Exploring the code using unit tests - these 2 functions do not work consistently
Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
Upstream-commit: e48a22282897c4755552fd79bf0d7af220116dc9
Component: engine
2015-08-28 10:29:52 +00:00
d4bbf5d640 Clean up ProgressStatus
- Rename to Broadcaster

- Document exported types

- Change Wait function to just wait. Writing a message to the writer and
  adding the writer to the observers list are now handled by separate
  function calls.

- Avoid importing logrus (the condition where it was used should never
  happen, anyway).

- Make writes non-blocking

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 26c9b585042ac7dce8db83478a69fd01a4b003d7
Component: engine
2015-08-27 13:22:08 -07:00
2b816e64e2 Show pull progress in terminal for inflight pull requests
Based on #12874 from Sam Abed <sam.abed@gmail.com>. His original commit
was brought up to date by manually porting the changes in pull.go into
the new code in pull_v1.go and pull_v2.go.

Fixes #8385

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 572f008e892b06262963ccb75c631f2f5d6c6fcd
Component: engine
2015-08-27 11:18:40 -07:00
4602da3b1b Merge pull request #15493 from stevvooe/no-buffer-on-push
Avoid buffering to tempfile when pushing with V2
Upstream-commit: 70a814c3f378a5873aedf3be85397272de4f6672
Component: engine
2015-08-26 13:59:01 -07:00
20b02657f2 Merge pull request #15865 from Microsoft/10662-isabs
Windows: Fix use of IsAbs check
Upstream-commit: 47cdae243a7e0108d487e88cab966ff09e8d94c0
Component: engine
2015-08-26 13:29:24 -07:00
799fa64220 Windows: Fix use of IsAbs check
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: f11ba3135b19006a47cf80861f3c291a3211eb1e
Component: engine
2015-08-26 12:38:28 -07:00
bfe1bbc7d2 Add volume API/CLI
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: b3b7eb2723461b1eb4be692f4bced0ae8ea9cb58
Component: engine
2015-08-26 13:37:52 -04:00
c4be78888c tarsum: add a big fat warning
Signed-off-by: Vincent Batts <vbatts@redhat.com>
Upstream-commit: 459451de8b6760034dd4bf7a782b7875441254a5
Component: engine
2015-08-25 16:50:08 -04:00
78b5767538 Avoid buffering to tempfile when pushing with V2
The practice of buffering to a tempfile during a pushing contributes massively
to slow V2 push performance perception. The protocol was actually designed to
avoid precalculation, supporting cut-through data push. This means we can
assemble the layer, calculate its digest and push to the remote endpoint, all
at the same time.

This should increase performance massively on systems with slow disks or IO
bottlenecks.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: 349aef06d51a9425f70a877585fe45283366c2c4
Component: engine
2015-08-24 18:08:05 -07:00
69dbe5953f Merge pull request #15393 from azurezk/exportImage-toplevel
change exportImage to top-level func
Upstream-commit: 82e2dec06de63d85db14c954e472deffdd18c5b7
Component: engine
2015-08-24 14:35:55 -07:00
26bf545a48 Merge pull request #14006 from hqhq/hq_add_kmem_limit
Add support for kernel memory limit
Upstream-commit: 9bd8a9b66bb493026599d22c7637909cb460d039
Component: engine
2015-08-21 14:34:27 -07:00
ad05d1ea8d Merge pull request #15125 from WeiZhang555/golint-stdcopy-system
fix golint warnings/errors on pkg/system and pkg/stdcopy
Upstream-commit: ecff4badcd98f749e5bd8511fbf4ca2c605db96c
Component: engine
2015-08-21 14:27:59 -07:00
2ec9a2ac53 Merge pull request #15218 from calavera/gender_unbiased_names
Add more amazing women to the names generator.
Upstream-commit: 008a8ffdd20f710bb177c299d4f3f5a2024894c4
Component: engine
2015-08-21 14:24:49 -07:00
b923556f4c Use a slice instead of a map of io.WriteClosers in broadcastwriter
Maps rely on the keys being comparable.
Using an interface type as the map key is dangerous,
because some interface types are not comparable.
I talked about this in my "Stupid Gopher Tricks" talk:
	https://talks.golang.org/2015/tricks.slide

In this case, if the user-provided writer is backed by a slice
(such as io.MultiWriter) then the code will panic at run time.

Signed-off-by: Andrew Gerrand <adg@golang.org>
Upstream-commit: 31cbf76d0c287d451182499d4fa0c4fda67e0716
Component: engine
2015-08-21 14:08:04 +01:00
2132326b0b Fix typo, "fil" -> "fill"
Signed-off-by: Icaro Seara <icaro.seara@gmail.com>
Upstream-commit: 997ba4b0da8c0596fd9fb108a7fcd4c79c1382ff
Component: engine
2015-08-19 21:50:54 -03:00
051aa5b9de Merge pull request #15684 from ibuildthecloud/dont-sync
Don't globally lock on driver initialization
Upstream-commit: 7f46dc03d5309997361f5be6e67088ec4ac410b7
Component: engine
2015-08-19 12:48:14 -04:00
3004521c7f Add support for kernel memory limit
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: b6f1b4ad350cbf1f540797eee44520694237d47c
Component: engine
2015-08-19 23:56:55 +08:00
68987b8336 Merge pull request #12927 from lindenlab/custom-host-port-ranges
Proposal: Change --publish=SPEC to allow binding to custom host port ranges
Upstream-commit: 59e49e1db0c4b59d8ca7334fdadade73755969b9
Component: engine
2015-08-19 17:04:23 +02:00
3ee024f425 Don't globally lock on driver initialization
This patch makes it such that plugin initialization is synchronized
based on the plugin name and not globally

Signed-off-by: Darren Shepherd <darren@rancher.com>
Upstream-commit: 164208fde5f1d4bcc4d75333e3309b678edac985
Component: engine
2015-08-18 22:25:30 -07:00
a2576f3ffa Merge pull request #15380 from calavera/remove_sys_info_pointers
Remove pointers from the SysInfo struct.
Upstream-commit: f1da5edc8b1404a302b02d38a60bba91c4bcd965
Component: engine
2015-08-17 18:40:54 -07:00
470c87b117 Adding support to publish on custom host port ranges
Signed-off-by: Don Kjer <don.kjer@gmail.com>

Changing vendor/src/github.com/docker/libnetwork to match lindenlab/libnetwork custom-host-port-ranges-1.7 branch
Upstream-commit: 47272f9cc563ea90d1f86df044f5429d15a37e4f
Component: engine
2015-08-15 02:41:29 +00:00
5e176c5f47 fix golint warnings/errors on pkg/system and pkg/stdcopy
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 7e420ad8502089e66ce0ade92bf70574f894f287
Component: engine
2015-08-13 18:47:13 +08:00
221348d130 Fixing Tar functions to support Windows long paths.
Signed-off-by: Stefan J. Wernli <swernli@microsoft.com>
Upstream-commit: 230cfc6ed21e9398b9b3df765e6c02e90031d728
Component: engine
2015-08-11 16:07:36 -07:00
7a08f892e2 Merge pull request #15404 from vbatts/vbatts-dm-zero-sized-field
devicemapper: fix zero-sized field access
Upstream-commit: 6f89a8ee1ba6b598dc1f76e829d6db6f830cdb8e
Component: engine
2015-08-10 09:16:11 -07:00
48bf8fcaf6 devicemapper: fix zero-sized field access
Fixes: #15279

Due to
7904946eeb
the devices field is dropped.

This solution works on go1.4 and go1.5

Signed-off-by: Vincent Batts <vbatts@redhat.com>
Upstream-commit: f83d05c3be3c3bcc84f6fa229504848ee8078321
Component: engine
2015-08-10 11:11:58 -04:00
33a35ed586 change exportImage to top-level func
Signed-off-by: Kun Zhang <zkazure@gmail.com>

remove useless FIXME

Signed-off-by: Kun Zhang <zkazure@gmail.com>

fix

Signed-off-by: Kun Zhang <zkazure@gmail.com>
Upstream-commit: a7c00bc1a23571dbd5e0085aac22a0e5b0d5fe40
Component: engine
2015-08-10 22:18:57 +08:00
89ab9698f7 Merge pull request #15074 from coolljt0725/14756_enable_golint_2
Enable golint in pkg/jsonlog and pkg/jsonmessage part of #14756
Upstream-commit: 764aa1a583ba6f73a32af1ba064401967cb716b6
Component: engine
2015-08-08 07:14:53 -04:00
305eb65786 Enable golint in pkg/jsonlog and pkg/jsonmessage.
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 5220f3b535ce38edbff616bc78f1eb92148d310e
Component: engine
2015-08-08 11:28:22 +08:00
2c6e673ce7 typofix - https://github.com/vlajos/misspell_fixer
Signed-off-by: Veres Lajos <vlajos@gmail.com>
Upstream-commit: 514623272398574c8fd7ef3fe42c5b2ae161349a
Component: engine
2015-08-07 23:25:49 +01:00
c3a2ab168f Merge pull request #15141 from Microsoft/10662-cp
Windows [TP3] - make docker cp functional
Upstream-commit: 04cd81401ad721cc3e1222c08fd81a1133737548
Component: engine
2015-08-06 17:15:09 -07:00
0f41d6e091 Remove pointers from the SysInfo struct.
Because they can just be values.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: c2bc637a0306657a86f3739bd5bdcd5db8d22539
Component: engine
2015-08-06 15:57:21 -07:00
0655529aa6 Move sysinfo out of daemon struct
sysinfo struct was initialized at daemon startup to make sure
kernel configs such as device cgroup are present and error out if not.
The struct was embedded in daemon struct making impossible to detect
if some system config is changed at daemon runtime (i.e. someone
umount the memory cgroup). This leads to container's starts failure if
some config is changed at daemon runtime.
This patch moves sysinfo out of daemon and initilize and check it when
needed (daemon startup, containers creation, contaienrs startup for
now).

Signed-off-by: Antonio Murdaca <runcom@linux.com>
(cherry picked from commit 472b6f66e03f9a85fe8d23098dac6f55a87456d8)
Upstream-commit: b2d06b6fba307a8972d08477ef8b711e31ace433
Component: engine
2015-08-06 15:46:09 -07:00
f147ed75c5 Merge pull request #15320 from hqhq/hq_add_cgroup_check
Check sysinfo for Cpuset cpu.shares and blkio
Upstream-commit: 9ce0a20c01ec0a8e0c3a1a45fba566600e7e9d4d
Component: engine
2015-08-06 14:23:37 -07:00
efe044b445 Windows - make docker cp functional
Signed-off-by: John Howard <jhoward@microsoft.com>

Conflicts:
	pkg/archive/copy.go

Make it compile

Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 2a237615c0915b60b8dc6c13a377bb766780ecbf
Component: engine
2015-08-06 11:22:38 -07:00
23d0cda657 Remove pkg/systemd
Signed-off-by: Antonio Murdaca <runcom@linux.com>
Upstream-commit: 931645c46056ae24b2df51c447b6df1a66b2ca30
Component: engine
2015-08-06 14:35:00 +02:00
9d9a4fd0c0 Merge pull request #15252 from coolljt0725/14765_enable_golint_3
Enable golint in pkg/archive
Upstream-commit: 8534090476b6eae66f1eca81e8bc0e0c61ed7197
Component: engine
2015-08-05 19:27:48 -04:00
f23264da83 Check sysinfo for Cpuset cpu.shares and blkio
Carried: #14015

If kernel is compiled with CONFIG_FAIR_GROUP_SCHED disabled cpu.shares
doesn't exist.
If kernel is compiled with CONFIG_CFQ_GROUP_IOSCHED disabled blkio.weight
doesn't exist.
If kernel is compiled with CONFIG_CPUSETS disabled cpuset won't be
supported.

We need to handle these conditions by checking sysinfo and verifying them.

Signed-off-by: Zefan Li <lizefan@huawei.com>
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: b7599d58cb103e3b13b3a51553fd69f5f8b60893
Component: engine
2015-08-05 22:35:18 +08:00
aa73b79fe2 Merge pull request #14921 from aaronlehmann/int64
Fix uses of "int" where "int64" should be used instead
Upstream-commit: 7374852be9def787921aea2ca831771982badecf
Component: engine
2015-08-04 19:16:13 -07:00
f031716448 Merge pull request #14840 from HuKeping/golint-pkg-sysinfo
Fix golint warning on pkg/sysinfo
Upstream-commit: 23dab01ed245c5a5132a2deb7ea26c0a984ec198
Component: engine
2015-08-04 20:57:39 +02:00
3ba45e7906 Enable golint in pkg/arcive
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: ba332b7d12fba16e8c604728a44986886eeb07d6
Component: engine
2015-08-04 09:52:54 +08:00
9d03f0053f Add more amazing women to the names generator.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 85a0f56fe73fc797a01f490032d9f7c88b7b4946
Component: engine
2015-08-03 17:19:36 -07:00