Commit Graph

402 Commits

Author SHA1 Message Date
003b985961 Fix die command when monitor returns
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 80f128a6ea2b71e2ed6838c6a913086859ed50ff
Component: engine
2014-01-21 16:18:57 -08:00
0c36be10c2 Merge pull request #3566 from tianon/fix-volume-symlinks
Fix symlink mounting issues
Upstream-commit: e56562c35e0ef39a02c171f60fccd6588edb8846
Component: engine
2014-01-21 11:37:05 -08:00
5de2521000 Don't expose cgroups via the execdriver API.
Use Resources to represent container limits rather than a cgroup specific field.

Docker-DCO-1.1-Signed-off-by: Paul Nasrat <pnasrat@gmail.com> (github: pnasrat)
Upstream-commit: 71c1646ba33da9b2567ad7a2f4cda0433c9718dd
Component: engine
2014-01-20 17:06:24 -05:00
c8d1294225 Extract cgroups pkg.
Initial move before enhancing cgroups package.

Docker-DCO-1.1-Signed-off-by: Paul Nasrat <pnasrat@gmail.com> (github: pnasrat)
Upstream-commit: 2553029959929184696e25ebdba4631ba7aeb8a6
Component: engine
2014-01-20 14:15:44 -05:00
20e6d0be01 Extract mount into pkg.
Mount is self contained and generic, it should be in pkg, to allow other pkg modules to use it.

Docker-DCO-1.1-Signed-off-by: Paul Nasrat <pnasrat@gmail.com> (github: pnasrat)
Upstream-commit: 2e094db6390dde57263c07665290b1477bb6df7e
Component: engine
2014-01-20 13:59:29 -05:00
70ed03954d Fix symlink mounting issues by evaluating symlinks directly on the LHS of a bind-mount -v and by FollowSymlinkInScope on the RHS just before mounting
Tested successfully with variations around mounting /var/run and /var/run/docker.sock inside a "debian" container directly at /var/run/docker.sock where /var/run is a symlink to "/run" on both the host and in the container.

Fixes #3262

Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
Upstream-commit: 7379a22a8d1687fc004a129ec86fd6eb01c39ede
Component: engine
2014-01-20 00:38:54 -07:00
8771a3eaee Move lxc template into lxc driver
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 70a5cb95b31c7596886b7f94d292444654b9af8d
Component: engine
2014-01-17 17:42:58 -08:00
72a4c2e064 Rename Capabilities in sysinfo and move it to its own subpackage
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: creack)

Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: crosbymichael)
Upstream-commit: 9e9f4b925b4b6a58a03bbff09150f1314d5fe3b2
Component: engine
2014-01-17 17:42:58 -08:00
ae872300fb Cleanup + add Info to driver in order to have specific IsRunning()
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: creack)

Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: crosbymichael)
Upstream-commit: 889b4b10ae3ec1d6e7879c30860aafd7674cb576
Component: engine
2014-01-17 17:42:22 -08:00
ecb354d61e Improve wait for lxc and driver interface
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 8c9f62d037a1bc82742ea316adaaf658af56b7c3
Component: engine
2014-01-17 17:42:22 -08:00
61d0d163e4 Use utils.Go to get error from monitor
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: c2b602b2ac7b5b3a67dbb7945e97a9f48b1a625e
Component: engine
2014-01-17 17:42:22 -08:00
016a7317fc Simplify chroot wait, address code review issues
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: f3f2456b0451d93a539eac63dac93a748e01317f
Component: engine
2014-01-17 17:42:22 -08:00
1e6d4ad1dd Move setup pty and standard pipes to funcs
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 8a38ead21993dd500280ae427895363a2de8be8a
Component: engine
2014-01-17 17:42:22 -08:00
b7aec1007b Remove SysinitPath from process
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 1e81387edcab600c9b8bc2a502988f7b3a2013e7
Component: engine
2014-01-17 17:42:22 -08:00
28c45914a4 Make exec driver run a blocking command
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: f846ecdc77bb9ab4d44b41a2e403bcf579d6b6e9
Component: engine
2014-01-17 17:42:22 -08:00
98268ad2c1 Add chroot driver for testing
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 8e0741f5e40d107780a5be1f6ae0f4d30ba43d7d
Component: engine
2014-01-17 17:42:22 -08:00
9b96c8681d Move RootIsShared to lxc driver
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 1d8455e6838f2630221eb3fcafeb382f9f7ce260
Component: engine
2014-01-17 17:42:22 -08:00
695537a626 Update with lxc unconfined changes
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 93ead2fe789a3a94a8433b12efcca782e0a7d7de
Component: engine
2014-01-17 17:42:22 -08:00
ecb0de6cea Fix network disabled for container
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 66782730b85db20600ce48fcab203a5eb43bcb02
Component: engine
2014-01-17 17:42:22 -08:00
f7fe9669ce Fix race in set running
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 77936ba1a1ff404b75ae8a34c6d4e280c23d9144
Component: engine
2014-01-17 17:42:22 -08:00
2e99b888c2 Fix race in cleanup
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 381d593d04fc46dac5b202d047981e15183c5ed1
Component: engine
2014-01-17 17:42:22 -08:00
1e4d16ab41 Fix race in TestRun
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: ad9710685ca3ae101c84a57c7d68a25cba4bede2
Component: engine
2014-01-17 17:42:22 -08:00
8eebe6db05 Update with container specific waitLock
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 8b60273f76723897a9831ca125500ede85e05b5d
Component: engine
2014-01-17 17:42:22 -08:00
a8716549d6 Rework monitor and waitlock inside of driver
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 8e87835968a4c6233406061759e3dca03ab86989
Component: engine
2014-01-17 17:42:22 -08:00
f9406fce53 WIP complete integration test run
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 5a3d9bd432fdaa95f870d4d99fad1d6fafeaad92
Component: engine
2014-01-17 17:42:21 -08:00
c1bfdbf247 Fix tty set issue for ioctl error
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 1c1cf54b0aa44553b714b82a1960b4f1199ac33a
Component: engine
2014-01-17 17:42:21 -08:00
d4ff7dd42c Embed exec.Cmd on Process
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 5573c744e4be16f39e1491188c4d4ff43f61d549
Component: engine
2014-01-17 17:42:21 -08:00
50773ecc52 Keep state in core on container
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 25a26977173632b5966838d910550a921ef5a853
Component: engine
2014-01-17 17:42:21 -08:00
dc2dffef1c Integrate process changes in container.go
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: f2680e5a5b1fc2393dfe319fe4dd197672985411
Component: engine
2014-01-17 17:42:21 -08:00
f50ee0d154 Add remount for bind mounts in ro
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: f231539e995a70a49903e9a852535d2c8a8eca43
Component: engine
2014-01-14 15:20:21 -08:00
a7ff45c891 Do not add hostname when networking is disabled
Docker-DCO-1.0-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Upstream-commit: 0354c3a95cf1f95ac9564b8e2897295e8a8613fd
Component: engine
2014-01-08 16:57:56 -08:00
72bcbfd669 Fix a few miscellaneous typos (Unkown -> Unknown, Recieve -> Receive)
Docker-DCO-1.0-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
Upstream-commit: e525ad3f9be05bfab388896ae559411650429553
Component: engine
2014-01-07 22:15:53 -07:00
a481c1b450 Move utility package 'term' to pkg/term
Upstream-commit: 7ce7516c12f58aa71cd055b7c0bef6585d3f2ab3
Component: engine
2013-12-23 23:42:37 +00:00
44050b9219 Allow mtu to be configured at daemon start
Upstream-commit: 566ff54d0ddffbeb3ba2e5f1e400db8528faf0a7
Component: engine
2013-12-20 12:12:03 -05:00
0bf2305d2f Move MTU setting outside of lxc and set with netlink
Upstream-commit: 0e6f0c4e02f4a29a1495f68f8aa52c5a10f587da
Component: engine
2013-12-19 11:51:44 -08:00
dbe3d58b07 Merge pull request #3271 from crosbymichael/mount-outside
Perform docker specific mounts outside of lxc
Upstream-commit: f21bd80e90af12745c7a8bf98d84ec50c3295987
Component: engine
2013-12-19 11:13:31 -08:00
dd4dc32856 Improve interface by moving to subpkg
Enable builds on OSX
Upstream-commit: 7bc96aec7bf978e87cb87935bd55f85e2cb1664a
Component: engine
2013-12-18 16:42:49 -08:00
a1f6c20284 prevent a panic with docker run -v /
Upstream-commit: 536da93380f1cacb82c344ad09c2daaae29f8ac3
Component: engine
2013-12-18 13:57:49 -08:00
8eec37c741 Handle external mounts outside of lxc
Upstream-commit: 45d7dcfea276841cce782feced3a2eb3eab01208
Component: engine
2013-12-18 13:46:02 -08:00
1beb5ed6c0 Merge pull request #3201 from jpoimboe/libvirt-prereq-network
Set hostname and IP address from dockerinit
Upstream-commit: f9328ad9cc5ecf2b1fcbf0c5b181907141149e4f
Component: engine
2013-12-13 10:38:17 -08:00
8538072ed6 dockerinit: propagate "container" env variable from lxc
Lxc (and libvirt) already set the "container" env variable
appropriately[1], so just use that.

[1] http://www.freedesktop.org/wiki/Software/systemd/ContainerInterface/
Upstream-commit: e8772943215fff3e17642ad410e4815e40e96b8b
Component: engine
2013-12-12 20:08:58 -06:00
bfaa130f9b dockerinit: set IP address
Set the IP address in dockerinit instead of lxc utils, to prepare for
using libvirt-lxc.
Upstream-commit: ecc51cd465da56b38190fe852cf9f31bdfbb0fdc
Component: engine
2013-12-12 19:57:11 -06:00
161e9b78f9 dockerinit: drop capabilities
Drop capabilities in dockerinit instead of with lxc utils, since
libvirt-lxc doesn't support it.

This will also be needed for machine container mode, since dockerinit
needs CAP_SYS_ADMIN to setup /dev/console correctly.
Upstream-commit: b8f1c7370516a4eec0d3168d594a7d7d92e7f8e9
Component: engine
2013-12-12 13:47:24 -06:00
bf9ceb198b Improve FollowLink to handle recursive link and be more strick
Upstream-commit: 8fd9633a6bb136af6666626a76056b1592fef0c7
Component: engine
2013-12-11 17:19:02 -08:00
19acae63e7 Fix volumes on the host by following symlinks in a scope
Upstream-commit: f396c42cad2b23dae5e3296c18fd6190f210c022
Component: engine
2013-12-11 16:31:02 -08:00
84ef86d05d don't open bind mounted files/dirs to get Stat, use os.Lstat
Upstream-commit: 761184df5295b72c5d1ab4549dcddb54977da487
Component: engine
2013-12-10 12:49:53 -06:00
e21c443f19 Extract volume bind, creation and external methods.
Make Start() slightly more readable.
Upstream-commit: 40fe9f581bd56bbcab9f231763cfac20e659d8c3
Component: engine
2013-12-03 18:58:31 -05:00
0c7bc6f2ce Extract helper method for volume linking.
Makes this more readable.
Upstream-commit: 84f78d9cad4162ddfc1bccbe55402050123cb1c5
Component: engine
2013-12-03 17:35:54 -05:00
8118fea381 Merge pull request #2775 from daniel-garcia/2671-bindmount_files
fixes #2671, add support for bind mounting individual files in to contai...
Upstream-commit: d6cdbca6c118a1022f6cb4cd5e260a01aa342009
Component: engine
2013-12-02 09:30:08 -08:00
fb39460944 Add a GetPtyMaster() method to container to retrieve the pty from an other package.
We could also have put ptyMaster public, but then we need to ignore it in json
otherwise the Marshalling fails. I think it is cleaner that way.
Upstream-commit: fbebe20bc69648c046e3818ca744ae246092a782
Component: engine
2013-11-29 07:40:44 -08:00