Commit Graph

43 Commits

Author SHA1 Message Date
b98eabeaed Validate mount paths on task create
This is intended as a minor fix for 1.12.1 so that task creation doesn't
do unexpected things when the user supplies erroneous paths.

In particular, because we're currently using hostConfig.Binds to setup
mounts, if a user uses an absolute path for a volume mount source, or a
non-absolute path for a bind mount source, the engine will do the
opposite of what the user requested since all absolute paths are
treated as binds and all non-absolute paths are treated as named
volumes.

Fixes #25253

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 38f8b0eb10725c40fb3c7e0719accd240cd39e22
Component: engine
2016-08-01 23:35:46 -04:00
326610d0c6 Merge pull request #25043 from stevvooe/forked-pull-context
container/controller: avoid cancellation with forked pull context
Upstream-commit: 7bb9676a2bab9517f06abf849cbe6e4337484a15
Component: engine
2016-07-26 01:01:09 -07:00
7501db1754 Merge pull request #25036 from nishanttotla/describe-function-update-executor
Using map to list plugins in node description
Upstream-commit: 301eba03e1f30e72e85b9c33b1d02476efad341d
Component: engine
2016-07-25 22:19:33 -07:00
bff0a1048f container/controller: avoid cancellation with forked pull context
Context cancellations were previously causing `Prepare` to fail
completely on re-entrant calls. To prevent this, we filtered out cancels
and deadline errors. While this allowed the service to proceed without
errors, it had the possibility of interrupting long pulls, causing the
pull to happen twice.

This PR forks the context of the pull to match the lifetime of
`Controller`, ensuring that for each task, the pull is only performed
once. It also ensures that multiple calls to `Prepare` are re-entrant,
ensuring that the pull resumes from its original position.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: d8d71ad5b94d44a2778f2d8989424259cac94e9b
Component: engine
2016-07-25 21:52:10 -07:00
09945aead8 Merge pull request #24967 from mavenugo/eligiblenet
improve error message when using ineligible network with service create
Upstream-commit: 1afa8195936e8988a61bea5cf753ec8a7aaaf5fa
Component: engine
2016-07-25 21:02:24 -07:00
088c389905 Merge pull request #25030 from stevvooe/allow-cancellation-propagation
swarm/controller: allow cancellation to propagate
Upstream-commit: a6a261261d94748b9c3eb06ddb1f64f426eec43b
Component: engine
2016-07-25 19:50:32 -07:00
6a43c7c1ad swarm/controller: allow cancellation to propagate
Ensure that cancellation of a pull propagates rather than continuing to
container creation. This ensures that the `Prepare` method is properly
re-entrant.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
Upstream-commit: d99c6b837ffd18ffe5bce801feb4936bf0edd2aa
Component: engine
2016-07-25 18:31:24 -07:00
2de0b34d83 Using map to list plugins in node description
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
Upstream-commit: feedb7ab5a139ba492a9b896e8efdc0b9ddc43b2
Component: engine
2016-07-25 17:45:32 -07:00
d759fd7b51 Merge pull request #24545 from runshenzhu/health-check
swarm: block controller.Start until container is healthy
Upstream-commit: a4634cd8a8edb9be9c73dc552e045fa868a861f7
Component: engine
2016-07-25 20:32:27 -04:00
5a95df9753 extend health check to start service
Signed-off-by: runshenzhu <runshen.zhu@gmail.com>
Signed-off-by: Runshen Zhu <runshen.zhu@gmail.com>
Upstream-commit: a99db84b4a966f0f09e81c446e857323a2a3302c
Component: engine
2016-07-25 15:49:22 -07:00
38618da388 Sort plugin names in node description
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
Upstream-commit: 227c7e4e8d8ce9ecb74ff1b38fe07cd6c37aee9f
Component: engine
2016-07-25 10:38:24 -07:00
4d19e2a5c0 improve error message when using ineligible network with service create
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 40c88b8c54fe4595f8bda5417ced3729eea5b16e
Component: engine
2016-07-25 08:31:22 -07:00
737108710c Merge pull request #24139 from runshenzhu/health-check
add health check in docker build-in swarm mode
Upstream-commit: e2fc1439a11cff5f719ae47265da135d26dd36ad
Component: engine
2016-07-11 09:43:59 -04:00
8d74981897 Add logdrivers to executor from swarmkit
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 8a50315f3ce89b24e3556dba288b2ce7b4daf026
Component: engine
2016-07-08 13:33:40 -07:00
7ac8dc18c4 Update executor volumes from swarmkit
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 6586f4f0719ae59c4a2b74acd91a1a888a0018b5
Component: engine
2016-07-08 13:33:40 -07:00
7ac01fb32e Use newer default values for mounts CLI
In the API:
`Writable` changed to `ReadOnly`
`Populate` changed to `NoCopy`

Corresponding CLI options updated to:
`volume-writable` changed to `volume-readonly`
`volume-populate` changed to `volume-nocopy`

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 56f3422468a0b43da7bae7a01762ce4f0a92d9ff
Component: engine
2016-07-06 22:34:39 -04:00
f773935c3b add health check in docker cluster
Signed-off-by: runshenzhu <runshen.zhu@gmail.com>
Upstream-commit: 1ded1f26e154e283ab26f347971d4d4a51edc94f
Component: engine
2016-07-06 13:43:20 -07:00
e4dfc2d04c Validate hostname starting from 1.24 API.
In order to keep a little bit of "sanity" on the API side, validate
hostname only starting from v1.24 API version.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 6daf3d2a783fd042e870c8af8bbd19fc28989505
Component: engine
2016-07-06 09:13:59 +02:00
a3ed3e2e3c Merge pull request #23947 from cpuguy83/fix_mount_target
Volume mounts need to use "Binds" API field
Upstream-commit: adb48487f2ec65a9facab04f1ec6c20aefb3e41f
Component: engine
2016-07-01 13:23:14 -07:00
b73379e968 Update to new swarmkit/engine-api
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 9b652738363d92fbe6e43b3981cdcc94bdb72c76
Component: engine
2016-06-30 17:22:47 -07:00
e32550579c Merge pull request #23584 from nishanttotla/private-images-swarm-services
Passing registry auth token for service create, update
Upstream-commit: 8fe6480c8a26f80fe174ae93e1b380bb7ec6083c
Component: engine
2016-06-30 17:18:59 -07:00
2cb691411c Volume mounts need to use "Binds" API field
Swarm was putting volume type mounts into the container config's
"Volumes" field, but really these need to go into "Binds".
"Volumes" is only for normal "-v /foo" volumes, not named volumes or
anything else.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 2bc2165cbf3e949921d1659f09841b5f008f590d
Component: engine
2016-06-30 17:00:52 -04:00
bd38c4db96 Added missing flags for swarm-mode networks
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: cf78863e9dc4e3480a7d1059ed306bdfd81cd3dc
Component: engine
2016-06-29 15:30:57 -07:00
cddb6e635c Updating header name and executor
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
Upstream-commit: af5df117a805c8df661c7efa58c57680019b5752
Component: engine
2016-06-29 13:26:19 -07:00
5fee17f637 Remove log warning on task update
This warning appears in the course of normal use of swarm mode. Since
it's meant more as an internal TODO than something which should be
exposed to a user, remove the log message.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 39c93cfb47783f2531ba44f062fd9a8b351d2224
Component: engine
2016-06-24 12:07:47 -07:00
a463fd07fe Merge pull request #23881 from tonistiigi/exec-wait
Fix error reporting on executor wait
Upstream-commit: e82dcf1c6de82680ae34a64735d0da0c080085ba
Component: engine
2016-06-24 11:18:49 -04:00
fbf0465b15 Merge pull request #23790 from tonistiigi/skip-pull
Skip always pulling images on integration tests
Upstream-commit: 487931902c1177352e4eceec1b5ef558a5ba24cc
Component: engine
2016-06-23 11:47:33 -07:00
9d859318a6 Fix error reporting on executor wait
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: c895a76f1076c782011e9decf58ab6548cf0fb35
Component: engine
2016-06-22 18:12:51 -07:00
a75adf3964 Merge pull request #23797 from liubin/fix-typo
fix some typos
Upstream-commit: 4962fea757415087755d7683e73bc0c7c7a39921
Component: engine
2016-06-22 11:56:48 +10:00
923b4bd8ef fix some typos
Signed-off-by: bin liu <liubin0329@gmail.com>
Upstream-commit: 950073aabb305db6156709ea8509b1f72ff06f3b
Component: engine
2016-06-21 15:29:25 +08:00
be80ca6785 Skip always pulling images on integration tests
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: e2226223e614716749cdb7701a130c7449f5f854
Component: engine
2016-06-20 17:45:29 -07:00
d62b2b14a2 Fix misspell typos
Signed-off-by: nick <nicholasrusso@icloud.com>
Upstream-commit: 7135afa79b4d99ba2a214fcc1c2decf95f850c2f
Component: engine
2016-06-19 09:53:31 -07:00
cb1d5362ed Merge pull request #23707 from mrjana/vendor
Vendoring swarmkit @3f135f206179e
Upstream-commit: b014d6a9174cb881dc8a7ff1ac258b343111a27e
Component: engine
2016-06-17 22:47:58 -07:00
467352d977 Vendoring swarmkit @3f135f206179e
Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
Upstream-commit: 64a567d24c147379dc79b54cf2140c4e7905c022
Component: engine
2016-06-17 19:01:18 -07:00
b282e08783 Change log.printf service creation msg to debug
Signed-off-by: tomwbarlow@gmail.com <tomwbarlow@gmail.com>
Upstream-commit: eed8d14ed16846f926e2d139e8232fbc2d4641e4
Component: engine
2016-06-17 15:03:11 +01:00
e79dde3c67 Update daemon to new swarmkit
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: a83bba467a8bd24924b1a0cf55b954ac49937b5b
Component: engine
2016-06-16 15:06:27 -07:00
a0153fe543 Merge pull request #23542 from mavenugo/aliases
Use service alias and configure service VIP or dns-rr
Upstream-commit: 011774e6f0eb5db13fb084b2b8d4d499a9f0548b
Component: engine
2016-06-15 16:18:50 -04:00
e306e601d2 Use service alias and configure container's --net-alias
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 07e39e9e7283a159efa18bc8f72cb2dc0e4f700f
Component: engine
2016-06-14 19:50:34 -07:00
b0143169a4 Merge pull request #23531 from tonistiigi/rm-race
Fix race on force deleting container created by task
Upstream-commit: bd92dd29b9436f4e6a16904e92ce2d965e994d2c
Component: engine
2016-06-15 02:33:56 +00:00
08261c5b09 Fix race on force deleting container created by task
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: dcfe99278db113e79dc037a6f854f4cea9eebe22
Component: engine
2016-06-14 16:49:04 -07:00
a05c8dd297 Daemon to support network restore
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: ecffb6d58cf89371e3f4a20f55c2e614dbdfe880
Component: engine
2016-06-14 16:45:25 -07:00
9371e0d883 fix 2 potential panics with mounts in swarm
Signed-off-by: Victor Vieux <vieux@docker.com>
Upstream-commit: ffeb9fcb2a155f3495be333f9c6df41ea14c809b
Component: engine
2016-06-14 09:25:39 -07:00
be63983b3a Add Swarm management backend
As described in our ROADMAP.md, introduce new Swarm management API
endpoints relying on swarmkit to deploy services. It currently vendors
docker/engine-api changes.

This PR is fully backward compatible (joining a Swarm is an optional
feature of the Engine, and existing commands are not impacted).

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Signed-off-by: Victor Vieux <vieux@docker.com>
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 534a90a99367af6f6bba1ddcc7eb07506e41f774
Component: engine
2016-06-13 22:16:18 -07:00