Commit Graph

1703 Commits

Author SHA1 Message Date
e92413dd0d Merge pull request #14371 from Microsoft/10662-graphdriver
Windows: Graph driver implementation
Upstream-commit: 4aeb84612f530d01e0b4f5b3fff40d2a6978f6f4
Component: engine
2015-07-10 15:35:00 -07:00
9f9bda0c57 Merge pull request #13669 from ewindisch/readonly-proc
Make /proc, /sys, & /dev readonly for readonly containers
Upstream-commit: 703248da20566f707b8290662805a9264629e2e0
Component: engine
2015-07-10 15:32:13 -07:00
1296feade8 Windows: Graph driver implementation
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 52f4d09ffb376ffaa6677cb1e0413c6a97f53f24
Component: engine
2015-07-10 14:33:11 -07:00
576b45a55d Merge pull request #13554 from Microsoft/10662-winexec
Windows: The real Windows exec driver is here.
Upstream-commit: b7e8169274ba4b897601e1025b91ebd361902213
Component: engine
2015-07-10 17:13:10 -04:00
c3450bd95b Windows: Exec driver
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 9ae9d4c87af8b04eb80006aca9f760ffdb1052bb
Component: engine
2015-07-10 13:36:56 -07:00
3a1c206f9b Merge pull request #14306 from Microsoft/validatepsfilter
Validate status= filter to docker ps
Upstream-commit: 20ac0e61643ec185052b8f29272aba1e95be76ec
Component: engine
2015-07-10 15:43:01 -04:00
c770b13f1f Add cgroup bind mount by default
Libcontainer already supported mount container's own cgroup into
container, with this patch, we can see container's own cgroup info
in container.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: f18fb5b3efd59d54c00d4e1b1d4b88c4b21e96be
Component: engine
2015-07-10 13:12:09 +08:00
8595d62a4c Windows: Fix docker info not to SIGSEGV
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 4348ad68f818ed72752bcf66d30f53cf15598bb4
Component: engine
2015-07-09 16:37:54 -07:00
18d3d40382 Merge pull request #14476 from crosbymichael/execid-growth-fix
Prevent uncontrolled exec config growth
Upstream-commit: 382799a64253a1da46613a2290a2f59d02710df8
Component: engine
2015-07-09 15:36:11 -07:00
e0ffc7b501 Use mark and sweep for exec command removal
This takes the final removal for exec commands in two steps.  The first
GC tick will mark the exec commands for removal and then the second tick
will remove the config from the daemon.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Upstream-commit: 34ab8c432691934745d66ee94ff4aec1120518e0
Component: engine
2015-07-09 14:51:10 -07:00
c104f21d9a Merge pull request #14484 from LK4D4/check_dockerinit_lxc
Check dockerinit only if lxc driver is used
Upstream-commit: c9e2a71509743ea38baafb71d7efa8b205af14b4
Component: engine
2015-07-09 14:47:03 -07:00
81d1e83005 Fix volumes-from mount references.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 3d029c3bf335bc2867d1efc803096d2912b81799
Component: engine
2015-07-09 09:01:57 -06:00
48bfe58a0d Check dockerinit only if lxc driver is used
This allow you to run dynamically linked docker without compiling
dockerinit.

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: 96bc377a8d293cf786722ebb0ff89a81d63e43ed
Component: engine
2015-07-08 14:12:51 -07:00
6d71e61742 Add GC loop to clean exec command refs on daemon
This adds an event loop for running a GC cleanup for exec command
references that are on the daemon.  These cannot be cleaned up
immediately because processes may need to get the exit status of the
exec command but it should not grow out of bounds.  The loop is set to a
default 5 minute interval to perform cleanup.

It should be safe to perform this cleanup because unless the clients are
remembering the exec id of the process they launched they can query for
the status and see that it has exited.  If they don't save the exec id
they will have to do an inspect on the container for all exec instances
and anything that is not live inside that container will not be returned
in the container inspect.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Upstream-commit: 5f017bba48e5c763157e1b35a5edea64cc41fc6a
Component: engine
2015-07-08 13:47:59 -07:00
51dfe1d73a Remove exec config from container after exit
This removes the exec config from the container after the command exits
so that dead exec commands are not displayed in the container inspect.
The commands are still kept on the daemon so that when you inspect the
exec command, not the container, you are still able to get it's exit
status.

This also changes the ProcessConfig to a pointer.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Upstream-commit: 04c9f86bdcf9f42deb09df76922a8c61205721a2
Component: engine
2015-07-08 10:55:42 -07:00
846e4076e7 Merge pull request #14471 from icecrime/14451_devmapper_startup_panic
Fix panic on devicemapper initialization
Upstream-commit: 3833c990e70fa691ce7d609740094e88e1a37af7
Component: engine
2015-07-08 11:18:00 -06:00
a095147db9 Fix panic on devicemapper initialization
The ability to save and verify base device UUID (#13896) introduced a
situation where the initialization would panic when removing the device
returns EBUSY.

Functions `verifyBaseDeviceUUID` and `saveBaseDeviceUUID` now take the
lock on the `DeviceSet`, which solves the problem as `removeDevice`
assumes it owns the lock.

Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
Upstream-commit: f08989902374a517b1f8e5e0bfd3b4ea59e5ba27
Component: engine
2015-07-08 09:10:20 -07:00
13ea01e391 Fix copy from a "created" container. Fixes #14420
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 289ee90b04a2315cd36d6ff363b41c89f8ebf2aa
Component: engine
2015-07-08 11:15:09 +08:00
78101e16cc Merge pull request #14100 from rhvgoyal/overlay-docker-inspect
overlay: Export metadata for container and image in docker-inspect
Upstream-commit: 2fe51ecee75801b6a937801ccd2839335a3f8c88
Component: engine
2015-07-07 18:11:27 -07:00
d7b0abae1e Merge pull request #14432 from coolljt0725/umount_rootf_on_cp_fail
Always umount container rootfs and volumes on docker cp failed
Upstream-commit: 045ccc4326c596c808711beda9a4f566d3ad5d61
Component: engine
2015-07-07 21:04:16 -04:00
682ea83bb3 Warn when udev_sync is not supported.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: e27131519f610178fd8adfc4b87c7bc2521a562f
Component: engine
2015-07-07 15:10:24 -06:00
c17c7fce57 Revert "Fix implicit DeviceMapper selection"
This reverts commit 0a376291b2213699f986a7bca1cc8c4f4ed00f8d.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 9af7afb9eb138bdba33c22445f36f41e5aa26bd1
Component: engine
2015-07-07 12:27:19 -07:00
eb7ca7510b Always umount container rootfs and volumes on docker cp failed
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 13c36ce65ec02c7d2ac564ccc9d4f69e92760d9a
Component: engine
2015-07-07 20:27:45 +08:00
800d4df14d Windows: Win32 event for sigusr1 linux equivalence
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: f4b08c7f5eed2eece239086f260eee9e736ee227
Component: engine
2015-07-06 18:58:53 -07:00
5d5c8a740d Validate status= filter to docker ps
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 7bf26d44b08de167b18257b5ddf5912585c840df
Component: engine
2015-07-02 16:12:42 -07:00
716fca6f61 Merge pull request #14349 from hqhq/hq_error_for_todisk
Show error message when todisk failed
Upstream-commit: 5b2d14fbbf1f4c237cf8f2a3c1b6ec802a68f135
Component: engine
2015-07-02 15:56:56 -07:00
793088ed0a Make /proc, /sys, /dev readonly for readonly containers
If a container is read-only, also set /proc, /sys,
& /dev to read-only. This should apply to both privileged and
unprivileged containers.

Note that when /dev is read-only, device files may still be
written to. This change will simply prevent the device paths
from being modified, or performing mknod of new devices within
the /dev path.

Tests are included for all cases. Also adds a test to ensure
that /dev/pts is always mounted read/write, even in the case of a
read-write rootfs. The kernel restricts writes here naturally and
bad things will happen if we mount it ro.

Signed-off-by: Eric Windisch <eric@windisch.us>
Upstream-commit: 5400d8873f730e6099d29af49fe45931665c3b49
Component: engine
2015-07-02 19:08:00 +00:00
bc7c7e9f54 Merge pull request #14292 from calavera/fix_driver_detection
Fix implicit DeviceMapper selection
Upstream-commit: f0ed68f852e33ed21420959790be4741725b03b1
Component: engine
2015-07-02 11:33:55 -07:00
740b021c6a Fix implicit DeviceMapper selection
DeviceMapper must be explicitly selected because the Docker binary might not be linked to the right devmapper library.

With this change, Docker fails fast if the driver detection finds the devicemapper directory but the driver is not the default option.
The option `override_udev_sync_check` doesn't make sense anymore, since the user must be explicit to select devicemapper, so it's being removed.
Docker fails to use devicemapper only if Docker has been built statically unless the option was explicit.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 0a376291b2213699f986a7bca1cc8c4f4ed00f8d
Component: engine
2015-07-02 09:21:27 -07:00
842ad32482 Replace latest log by logrus
Related to #11618 and #11614

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 10e114fb956db1b1a8bc9308cc6d14cbf30a5bab
Component: engine
2015-07-02 16:11:52 +02:00
2639bef2c5 Show error message when todisk failed
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: af7f81878f561ecdab32936d4bea72f0ab26ce0e
Component: engine
2015-07-02 18:24:35 +08:00
e43d7e0bfd Merge pull request #14324 from aboch/ds
Stats API to retrieve nw stats from libnetwork
Upstream-commit: 75864dcb385e7f27870e5b0c2383dfd0e0748258
Component: engine
2015-07-01 15:19:46 -07:00
4d0125faee Fix regression in parsing capabilities list when a single string is given
Signed-off-by: Antonio Murdaca <runcom@linux.com>
Upstream-commit: 10a3061c5f342477703e96d9b8b2e877d9cdddf5
Component: engine
2015-07-01 21:28:02 +02:00
908ab87a15 Stats API to retrieve nw stats from libnetwork
- Container networking statistics are no longer
  retrievable from libcontainer after the introduction
  of libnetwork. This change adds the missing code
  for docker daemon to retireve the nw stats from
  Endpoint.

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 8b40e44c395fb307cceb6f179ffe02030b316535
Component: engine
2015-07-01 11:15:16 -07:00
5607e48f25 Fix regression in containers attach/wsattach api, return not found before hijacking
Signed-off-by: Antonio Murdaca <runcom@linux.com>
Upstream-commit: 88d32a6109a15633481f758c4d0689516ae58aef
Component: engine
2015-07-01 18:16:17 +02:00
5290116562 Nat was moved to pkg/nat
Somehow this import was missed

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: d9af8551f82aff9e4fdaed2a8d250845b12dcf53
Component: engine
2015-06-30 16:48:17 -04:00
7f87043716 Merge pull request #14294 from mavenugo/bnone
fixed incorrect assumption on --bridge=none treated as disable network
Upstream-commit: a2621ac6dacf87bf713ac327f7c0e14eb77e52bc
Component: engine
2015-06-30 13:40:52 -07:00
7f4872fe6c Merge pull request #14297 from pwaller/move-nat-pkg
Move /nat to /pkg/nat
Upstream-commit: caa4acc7b11cbefb74d0b066d4a0752f4a11c5ee
Component: engine
2015-06-30 13:23:30 -07:00
521162c904 fixed incorrect assumption on --bridge=none treated as disable network
libnetwork host, none and bridge driver initialization is incorrectly
disabled if the daemon flag --bridge=none. The expected behavior of
setting --bridge as none is to disable the bridge driver alone and let
all other modes to be operational.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: c9328c6ccf120abda297d11fcfc7e60c7c31ec21
Component: engine
2015-06-30 13:04:28 -07:00
748772ece4 Validate Port specifications on daemon side
Fixes #14230

Signed-off-by: Ankush Agarwal <ankushagarwal11@gmail.com>
Upstream-commit: 477201a2954349bfe7ab63f73b11cd19d0f782d0
Component: engine
2015-06-30 12:14:49 -07:00
d99f89f02c Merge pull request #14268 from unclejack/lower_allocations_execdriver
daemon: lower allocations
Upstream-commit: bb364ff459e8ebcc601a13057a1477336646474b
Component: engine
2015-06-30 12:12:06 -07:00
9161e24479 Move /nat to /pkg/nat
By convention /pkg is safe to use from outside the docker tree, for example
if you're building a docker orchestrator.

/nat currently doesn't have any dependencies outside of /pkg, so it seems
reasonable to move it there.

This rename was performed with:

```
gomvpkg -vcs_mv_cmd="git mv {{.Src}} {{.Dst}}" \
	-from github.com/docker/docker/nat \
        -to   github.com/docker/docker/pkg/nat

```

Signed-off-by: Peter Waller <p@pwaller.net>
Upstream-commit: 9c2374d19623581028f070bc93fa4c60a660dce4
Component: engine
2015-06-30 17:43:17 +01:00
b565b94e85 daemon: lower allocations
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Upstream-commit: c1477db04fc32621652cf6a8fd2976b6bbf2066e
Component: engine
2015-06-30 01:45:31 +03:00
f1c962082a Merge pull request #14133 from Microsoft/10662-netmode
Windows: Refactor network modes
Upstream-commit: 18d5d3ba0332f95a294f09cd8c3ac9aeada0a4a5
Component: engine
2015-06-29 15:02:42 -07:00
fec4b99167 Merge pull request #14218 from calavera/fix_exec_user
Default process user to container config user.
Upstream-commit: 475ae0889e2d460084e6ba9bb047b8acbc87c535
Component: engine
2015-06-29 14:31:45 -07:00
0a2b0f80c4 Windows: Refactor network modes
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: c5e6a4b307d93c066c07b7664ffc676708b42391
Component: engine
2015-06-29 13:13:55 -07:00
73973301dc Default process user to container config user.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 0faa4518ed2dad592bb238838b4df2b34d2171c3
Component: engine
2015-06-29 12:52:05 -07:00
a8c9aef74e Merge pull request #14061 from runcom/clean-builder-daemon-config
Add struct to configure Builder commit
Upstream-commit: d543a01e17ace181261dd7809bbeec0c6580b867
Component: engine
2015-06-29 11:04:05 -07:00
4f74d3f3bd Closes #13323 and carries
Entering comments

Signed-off-by: Mary Anthony <mary@docker.com>
Upstream-commit: 078b23a37daf95101bf31bafc7f8396af7ad7d98
Component: engine
2015-06-29 06:18:41 -07:00
786eafcf79 Merge pull request #14120 from mdavranche/tempDir
tempDir (in the root dir), must be created after the root dir.
Upstream-commit: 2d15b35f7afaf496ecfbfd61e2c102033255386e
Component: engine
2015-06-26 11:46:55 -07:00