Commit graph

26031 commits

Author SHA1 Message Date
Tibor Vass
7bb9676a2b Merge pull request #25043 from stevvooe/forked-pull-context
container/controller: avoid cancellation with forked pull context
2016-07-26 01:01:09 -07:00
Tibor Vass
4144e11d32 Merge pull request #25041 from mavenugo/rip
Vendoring libnetwork to remove stale xfrm states
2016-07-25 23:05:58 -07:00
Tibor Vass
5a8f2ac86e Merge pull request #25038 from tiborvass/carry-25001
Carry 25001: Add container labels to service create/update
2016-07-25 23:05:20 -07:00
Tibor Vass
3c038318e5 Merge pull request #25021 from dmcgowan/fix-24951
Fix calculation of relative path for symlink on docker save
2016-07-25 22:24:45 -07:00
Tibor Vass
301eba03e1 Merge pull request #25036 from nishanttotla/describe-function-update-executor
Using map to list plugins in node description
2016-07-25 22:19:33 -07:00
Stephen J Day
d8d71ad5b9
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>
2016-07-25 21:52:10 -07:00
Tibor Vass
1afa819593 Merge pull request #24967 from mavenugo/eligiblenet
improve error message when using ineligible network with service create
2016-07-25 21:02:24 -07:00
Tibor Vass
a6a261261d Merge pull request #25030 from stevvooe/allow-cancellation-propagation
swarm/controller: allow cancellation to propagate
2016-07-25 19:50:32 -07:00
Madhu Venugopal
6a754a4eef Vendoring libnetwork to remove stale xfrm states
When using encrypted vxlan network, some of the xfrm states are left
stale. This fix also filters out self advertise-addr rules.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2016-07-25 19:44:07 -07:00
Tibor Vass
e462b4507a Prevent panic on update --container-label-add
Signed-off-by: Tibor Vass <tibor@docker.com>
2016-07-25 19:17:06 -07:00
Vincent Demeester
4031d70d1b Add container labels to service create/update
Swarm mode makes it possible through the API to set labels to containers
but not through command line. This tries to fix it.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-07-25 18:57:02 -07:00
Stephen J Day
d99c6b837f
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>
2016-07-25 18:31:24 -07:00
Tibor Vass
afac3361dc Merge pull request #25023 from cpuguy83/25022_fix_label_panic
fix panic on --label-add
2016-07-25 18:13:15 -07:00
Nishant Totla
feedb7ab5a
Using map to list plugins in node description
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
2016-07-25 17:45:32 -07:00
Brian Goff
a4634cd8a8 Merge pull request #24545 from runshenzhu/health-check
swarm: block controller.Start until container is healthy
2016-07-25 20:32:27 -04:00
Tibor Vass
8c7468bf3b Merge pull request #24856 from tiborvass/remove-status-2-from-healthcheck
healthcheck: do not interpret exit code 2 as "starting"
2016-07-25 16:34:43 -07:00
Brian Goff
85bc3194aa fix panic on --label-add
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2016-07-25 19:20:44 -04:00
runshenzhu
a99db84b4a extend health check to start service
Signed-off-by: runshenzhu <runshen.zhu@gmail.com>
Signed-off-by: Runshen Zhu <runshen.zhu@gmail.com>
2016-07-25 15:49:22 -07:00
Tibor Vass
ebb157ec46 Merge pull request #25018 from nishanttotla/stable-node-description-swarmkit
Sort plugin names in node description
2016-07-25 15:45:25 -07:00
Tibor Vass
91e9f38313 healthcheck: do not interpret exit code 2 as "starting"
Instead reserve exit code 2 to be future proof, document that it should
not be used. Implementation-wise, it is considered as unhealthy, but
users should not rely on this as it may change in the future.

Signed-off-by: Tibor Vass <tibor@docker.com>
2016-07-25 14:28:45 -07:00
Vincent Demeester
8f11896a45 Merge pull request #24949 from Microsoft/jjh/tasklist-tlist
Windows: nanoserver TestBuildCmdShellArgsEscaped
2016-07-25 22:58:09 +02:00
Derek McGowan
5487881e12 Fix calculation of relative path for symlink on docker save
Relative paths are now calculated from a base path rather than from the file path, which gets treated like a directory.
Symlinks will now properly point to the file as "../<layer dir>/layer.tar" rather the incorrect "../../<layer dir>/layer.tar".

Fixes #24951

Signed-off-by: Derek McGowan <derek@mcgstyle.net> (github: dmcgowan)
2016-07-25 13:28:10 -07:00
Nishant Totla
227c7e4e8d
Sort plugin names in node description
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
2016-07-25 10:38:24 -07:00
Sebastiaan van Stijn
e306466569 Merge pull request #24857 from abronan/swarm_admin_docs
Swarm docs: add administration guide for Managers and Raft
2016-07-25 19:28:21 +02:00
Alexandre Beslic
24f87f26e7 swarm docs: add administration guide for Managers and Raft
This adds a guide with recommendations on how to setup
Managers and keep the Swarm cluster healthy.

Signed-off-by: Alexandre Beslic <alexandre.beslic@gmail.com>
2016-07-25 10:25:33 -07:00
Sebastiaan van Stijn
caedb3f827 Merge pull request #24207 from sfsmithcha/add_swarm_mode_guide
add run swarm mode guide
2016-07-25 19:21:01 +02:00
Tibor Vass
c65925f24b Merge pull request #24943 from aaronlehmann/rolling-updates
Add failure action for rolling updates
2016-07-25 10:15:28 -07:00
Tibor Vass
79de4d2186 Merge pull request #24908 from jhorwit2/jah/24903
Treat HEALTHCHECK NONE the same as not setting a healthcheck
2016-07-25 10:14:38 -07:00
Sebastiaan van Stijn
1315573093 Merge pull request #25012 from aanand/entrypoint-note
Add note about --entrypoint overriding default command
2016-07-25 19:11:24 +02:00
Charles Smith
c406711cc0 add run swarm mode guide
Signed-off-by: Charles Smith <charles.smith@docker.com>
2016-07-25 10:10:11 -07:00
Michael Crosby
b6197e9514 Merge pull request #24942 from anusha-ragunathan/plugin-liverestore
Handle plugin shutdown when liveRestore is set.
2016-07-25 09:49:34 -07:00
Michael Crosby
e95d0b6bf1 Merge pull request #24984 from mlaventure/fix-restore-without-restore
Fix restoring behavior when live-restore is not set
2016-07-25 09:49:12 -07:00
Tibor Vass
087ca1b3b7 Merge pull request #24917 from aluzzardi/improve-service-error-reporting
service tasks: Improve error reporting
2016-07-25 09:44:08 -07:00
Aanand Prasad
2b7548f972 Add note about --entrypoint overriding default command
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-25 17:21:23 +01:00
Aaron Lehmann
57ae29aa74 Add failure action for rolling updates
This changes the default behavior so that rolling updates will not
proceed once an updated task fails to start, or stops running during the
update. Users can use docker service inspect --pretty servicename to see
the update status, and if it pauses due to a failure, it will explain
that the update is paused, and show the task ID that caused it to pause.
It also shows the time since the update started.

A new --update-on-failure=(pause|continue) flag selects the
behavior. Pause means the update stops once a task fails, continue means
the old behavior of continuing the update anyway.

In the future this will be extended with additional behaviors like
automatic rollback, and flags controlling parameters like how many tasks
need to fail for the update to stop proceeding. This is a minimal
solution for 1.12.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2016-07-25 08:51:19 -07:00
Madhu Venugopal
3e7d864925 Merge pull request #25003 from thaJeztah/make-network-error-less-DRY
make network errors less DRY
2016-07-25 08:47:29 -07:00
Madhu Venugopal
40c88b8c54 improve error message when using ineligible network with service create
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2016-07-25 08:31:22 -07:00
Josh Horwitz
4016038bd3 Treat HEALTHCHECK NONE the same as not setting a healthcheck
Signed-off-by: Josh Horwitz <horwitzja@gmail.com>
2016-07-25 11:11:14 -04:00
Brian Goff
19ec73b8b5 Merge pull request #24997 from WeiZhang555/fix-unmeaningful-log
small nit: fix unmeaningful log
2016-07-25 10:33:57 -04:00
Zhang Wei
af8359562c small nit: fix unmeaningful log
Truncated dir name can't give any useful information, print whole dir
name will.

Bad debug log is like this:

```
DEBU[2449] aufs error unmounting /var/lib/doc: no such file or directory
```

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
2016-07-26 07:10:28 +08:00
Sebastiaan van Stijn
3fa9d77bf3 make network errors less DRY
There's existing code to generate these
kind of errors, so make the errors added
in commit cc493a52a4
less DRY.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-07-25 16:22:08 +02:00
Vincent Demeester
e64f5f97fc Merge pull request #25002 from thaJeztah/add-new-errors-to-api-docs
Add new error to API docs
2016-07-25 16:00:36 +02:00
Brian Goff
11501fa60c Merge pull request #23908 from capkurmagati/fix-docker-stats
Fix high cpu usage caused by docker stats.
2016-07-25 09:54:00 -04:00
Sebastiaan van Stijn
42f2205184 Merge pull request #23844 from tjanez/docs-systemd-expand
Expand instructions on using systemd to manage containers
2016-07-25 14:39:45 +02:00
Sebastiaan van Stijn
b0089e4827
Add new error to API docs
Commit cc493a52a4 added
a constraint to network connect/disconnect operations
on "Swarm scoped" networks.

This adds those errors to the API documentation. Also
changes the error to lowercase for consistency.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-07-25 12:04:55 +02:00
Vincent Demeester
3056e4884e Merge pull request #24990 from mavenugo/rc5ln
Vendoring libnetwork for rc5
2016-07-25 11:43:59 +02:00
Sebastiaan van Stijn
cc493a52a4 Merge pull request #24988 from mavenugo/snconnect
Prevent network connect/disconnect on swarm scoped networks
2016-07-25 10:46:45 +02:00
Sebastiaan van Stijn
4b94a6cb16 Merge pull request #24991 from everett-toews/fix-AuthzPlugin
Fix AuthzPlugin URL fragment in docs
2016-07-25 10:32:03 +02:00
Vincent Demeester
bff9a0556f Merge pull request #24961 from jstarks/vt_th2_fix
Windows: Restore console mode on set mode failure
2016-07-25 09:49:34 +02:00
Vincent Demeester
1f3b400d3c Merge pull request #24977 from lixiaobing10051267/masterNote
Modify several fun notes in fsnotify.go
2016-07-25 09:41:17 +02:00