Commit graph

30028 commits

Author SHA1 Message Date
Sebastiaan van Stijn
a58b5830b1 Merge pull request #26576 from allencloud/change-cluster-response-status-code
update response status code for cluster request
2016-12-19 18:31:45 +01:00
Vincent Demeester
38886bbd74 Merge pull request #29513 from thaJeztah/fix-anonymous-volumes
fix conversion of anonymous volumes in compose-file
2016-12-19 17:16:00 +01:00
Sebastiaan van Stijn
d477a24ec5 Merge pull request #29539 from vdemeester/integration-remove-workingdir
[test-integration] global variable workingDirectory is not needed…
2016-12-19 15:18:02 +01:00
Sebastiaan van Stijn
fc5b5a4d1b Merge pull request #29543 from EnergyLiYN/br2
Header has incorrect punctuation.
2016-12-19 14:54:51 +01:00
Vincent Demeester
8a41c1d548 Merge pull request #29541 from tim-zju/spellError
spell error: in other parts, they are lower-case
2016-12-19 14:48:31 +01:00
lyn
c2ff923907 Header has incorrect punctuation.
Signed-off-by: lyn <energylyn@zju.edu.cn>
2016-12-19 21:38:59 +08:00
Sebastiaan van Stijn
05dc9846e1
remove client-side for supported logging drivers
The `docker logs` command performed a
client-side check if the container's
logging driver was supported.

Now that we allow the client to connect
to both "older" and "newer" daemon versions,
this check is best done daemon-side.

This patch remove the check on the client
side, and leaves validation to the daemon,
which should be the source of truth.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-12-19 14:30:01 +01:00
janonymous
f25e5ceeca Change -tlsverify to --tlsverify (Bug Fix: #29521)
Signed-off-by: Jaivish Kothari <janonymous.codevulture@gmail.com>
2016-12-19 18:03:57 +05:30
Evelyn.Xu
054e479bfa correct the spelling error of driver (#29523)
Signed-off-by: erxian <evelynhsu21@gmail.com>
2016-12-19 07:33:36 -05:00
Vincent Demeester
3dd25b9790
Global variable workingDirectory is not needed…
… and given where it was used, it should be quicker to create an empty
folder instead of passing potentially a big context with unrelated file.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-12-19 13:25:11 +01:00
Vincent Demeester
eb59c6d587 Merge pull request #29378 from aaronlehmann/swarm-plugins
Support v2 plugins in swarm mode
2016-12-19 11:07:06 +01:00
Sebastiaan van Stijn
48f7388e92 Merge pull request #29373 from vdemeester/remove-daemon-fmt-flood
Remove some fmt.Printf from integration-cli/daemon…
2016-12-19 10:59:25 +01:00
Vincent Demeester
0f68ecd3f7 Merge pull request #29441 from coolljt0725/fix_update_restart_policy
Fix docker update clear restart policy of monitor
2016-12-19 10:30:04 +01:00
lixiaobing10051267
9501f2ea97 Use wrong ApplyLayer in diff_windows.go
Signed-off-by: lixiaobing10051267 <li.xiaobing1@zte.com.cn>
2016-12-19 17:21:18 +08:00
Sebastiaan van Stijn
616adf1799 Merge pull request #29393 from lixiaobing10051267/masterDockerUpdate
Add docker-update description ommitted in docker.1.md
2016-12-19 10:17:14 +01:00
Vincent Demeester
309df6a592 Merge pull request #29510 from albers/docs-remove-node-ps--all
Remove `--all|-a` from `docker node ps` reference
2016-12-19 09:31:43 +01:00
lixiaobing10051267
c499ce266a Add docker-update description ommited in docker.1.md
Signed-off-by: lixiaobing10051267 <li.xiaobing1@zte.com.cn>
2016-12-19 15:13:51 +08:00
tim-zju
4bf9e7caaa spell error: in other parts, they are lower-case
Signed-off-by: tim-zju <21651152@zju.edu.cn>
2016-12-19 13:05:11 +08:00
allencloud
29d4a7f512 update response status code for cluster request
Signed-off-by: allencloud <allen.sun@daocloud.io>
2016-12-19 10:21:10 +08:00
Michael
e85bb788de [docs,man] Fixed typo (#29516)
Signed-off-by: Michael Käufl <docker@c.michael-kaeufl.de>
2016-12-18 19:55:09 -05:00
Sebastiaan van Stijn
120241937e
Improve validation for volume specs
The current validation only checked for the
number of elements in the volume-spec, however,
did not validate if the elements were empty.

Because of this, an empty volume-spec (""),
or volume spec only containing separators ("::")
would not be invalidated.

This adds a simple check for empty elements in
the volume-spec, and returns an error if
the spec is invalid.

A unit-test is also added to verify the behavior.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-12-19 01:50:08 +01:00
Sebastiaan van Stijn
6138a02c87 Merge pull request #29497 from yongtang/29486-docker-build-tmp-file
Clean up tmp files for interrupted `docker build`
2016-12-18 23:59:00 +01:00
Vincent Demeester
c1c6b51a91 Merge pull request #29509 from albers/completion-remove-node-ps--all
Remove bash completion for `docker node ps --all|-a`
2016-12-18 17:56:42 +01:00
Sebastiaan van Stijn
34889e579f
fix conversion of anonymous volumes in compose-file
the `convertVolumeToMount()` function did not take
anonymous volumes into account when converting
volume specifications to bind-mounts.

this resulted in the conversion to try to
look up an empty "source" volume, which
lead to an error;

    undefined volume:

this patch distinguishes "anonymous"
volumes from bind-mounts and named-volumes,
and skips further processing if no source
is defined (i.e. the volume is "anonymous").

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-12-18 16:50:32 +01:00
Harald Albers
364e900237 Remove --all|-a from docker node ps reference
Signed-off-by: Harald Albers <github@albersweb.de>
2016-12-18 06:47:54 -08:00
Harald Albers
a54cc4f88d Remove bash completion for docker node ps --all|-a
Signed-off-by: Harald Albers <github@albersweb.de>
2016-12-18 06:31:25 -08:00
Sebastiaan van Stijn
4436a5946d Merge pull request #28629 from yongtang/28581-secret-create-input
Add `--file` flag for `docker secret create` command
2016-12-18 03:04:10 +01:00
Sebastiaan van Stijn
f6ba8498a2 Merge pull request #28160 from AkihiroSuda/update-experimental-md
update experimental/README.md
2016-12-18 03:02:07 +01:00
Yong Tang
32de162fc9 Improve error output for docker stats ...
While looking into `docker stats <c1> <c2> ...` I noticed that
the error output is quite long, especially if there are multiple errors:
```sh
ubuntu@ubuntu:~/docker$ docker stats nofound
: Error response from daemon: No such container: nofound
ubuntu@ubuntu:~/docker$ docker stats nofound foo bar
: Error response from daemon: No such container: nofound, : Error response from daemon: No such container: foo, : Error response from daemon: No such container: bar
```

There are several issues,
1. There is an extra `: ` at the beginning. That is because if container is not found,
the name will not be available from the daemon.
2. Multiple errors are concatenated with `, ` which will be quite long.

This fix:
1. Only prient out the error from daemon.
2. Multiple errors are printed out line by line.

Below is the new output:
```sh
ubuntu@ubuntu:~/docker$ docker stats nofound
Error response from daemon: No such container: nofound
ubuntu@ubuntu:~/docker$ docker stats nofound foo bar
Error response from daemon: No such container: nofound
Error response from daemon: No such container: foo
Error response from daemon: No such container: bar
```

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2016-12-17 16:51:11 -08:00
Sebastiaan van Stijn
ee88de7385 Merge pull request #29494 from thaJeztah/fix-powershell-dco-check
fix powershell dco check
2016-12-17 21:34:51 +01:00
Sebastiaan van Stijn
2121041944 Merge pull request #29423 from unclejack/api_cli_integ_return
return directly without ifs in remaining packages
2016-12-17 21:30:47 +01:00
Yong Tang
847564fa49 Clean up tmp files for interrupted docker build
This fix tries to fix the issue raised in 29486 where interrupted
`docker build` leaves some tmp files in `/var/lib/docker/tmp`.
With tmp file name prefixed with `/var/lib/docker/tmp/docker-builderXXXXXX`.

The reason for the issue is that in `MakeTarSumContext()`:
```
	if err := chrootarchive.Untar(sum, root, nil); err != nil {
		return nil, err
	}
```
the `err` is shadowed and caused the clean up function in `defer func()`
not being called.

This fix fixes the issue.

This fix is tested manually, as was specified in 29486:
```
rm -rf /var/lib/docker/tmp

mkdir repro && cd repro
fallocate -l 300M bigfile

cat > Dockerfile <<EOF
FROM scratch
COPY ./bigfile /
EOF

docker build .
{Cancel}

ls -la /var/lib/docker/tmp
```

This fix fixes 29486.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2016-12-16 21:11:53 -08:00
Lei Jitang
737b5b1781 Fix update clear the restart policy of monitor
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2016-12-16 20:57:05 -05:00
Aaron Lehmann
545b97e6bc Merge pull request #29439 from lixiaobing10051267/masterWalk
rectify function and variable referred in pkg/archive/changes_linux.go
2016-12-16 17:25:09 -08:00
Ying Li
a6a0880a22 Before asking a user for the unlock key when they run docker swarm unlock, actually
check to see if the node is part of a swarm, and if so, if it is unlocked first.
If neither of these are true, abort the command.

Signed-off-by: Ying Li <ying.li@docker.com>
2016-12-16 17:16:55 -08:00
Tõnis Tiigi
8a8416ccbd Merge pull request #29456 from cpuguy83/fix_client_events_race
Fixes a race condition in client events monitoring
2016-12-16 17:07:43 -08:00
Sebastiaan van Stijn
110a95717d Merge pull request #29459 from yongtang/29365-follow-up
Allow containers to continue even if mount failed after live restore
2016-12-17 01:46:25 +01:00
Sebastiaan van Stijn
611a633ba4
fix powershell dco check
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-12-16 23:48:27 +01:00
Vincent Demeester
914a72541f Merge pull request #29003 from dnephin/pkg-compose-transform
Move composefile -> engine api type conversion to `cli/compose/convert`
2016-12-16 23:34:41 +01:00
Hongbin Lu
ce25f1d5db Add Fuxi Volume Plugin to the docs
Signed-off-by: Hongbin Lu <hongbin034@gmail.com>
2016-12-16 13:04:40 -06:00
Victor Vieux
4f57b94f0c Merge pull request #29042 from cpuguy83/fix_volume_plugin_refcounts
Fix volume plugin refcounting on daemon restart
2016-12-16 10:54:30 -08:00
Aaron Lehmann
45990d6e61 Add integration test for volume plugins on swarm
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2016-12-16 10:45:47 -08:00
Aaron Lehmann
53d447c5d5 Fix volume Create to check against canonical driver name
Previously, it was comparing against the driver name passed in by the
caller. This could lead to subtle issues when using plugins, like
"plugin" vs. "plugin:latest".

Also, remove "conflict:" prefix to improve the error message.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2016-12-16 10:45:46 -08:00
Aaron Lehmann
87e8828dff Merge pull request #29482 from thaJeztah/not-for-workers-only
swarm leave is not only for workers
2016-12-16 09:48:35 -08:00
Daniel Nephin
643fd775ed Move pkg to cli/compose/convert
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-12-16 12:27:31 -05:00
Daniel Nephin
4664dd06f1 More unit tests for converting services in stack deploy
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-12-16 12:20:07 -05:00
Daniel Nephin
655e48e653 Move ConvertService to composetransform package.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-12-16 12:20:07 -05:00
Daniel Nephin
7685e80fc9 Move ConvertVolumes to composetransform package.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-12-16 11:51:13 -05:00
Daniel Nephin
6b778c9633 Move ConvertNetworks to composetransform package.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-12-16 11:51:13 -05:00
Sebastiaan van Stijn
ba76c9214d Merge pull request #29434 from yuexiao-wang/pause-and-unpause
Fix inconsistency for pause and unpause
2016-12-16 16:42:04 +01:00