Commit Graph

2801 Commits

Author SHA1 Message Date
7994679b80 update status code for network api
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 56dca8b676cee2781021cb1138f48d42ace415a4
Component: engine
2017-04-14 10:11:17 +08:00
2f2bd517f5 Merge pull request #32464 from allencloud/add-status-code-400-for-update-endpoint
add status code 400 for update endpoints in swagger.yml
Upstream-commit: 05930120a0dadd6bca293464b511623d39231f95
Component: engine
2017-04-13 10:33:04 +02:00
203ab34184 Merge pull request #32532 from dnephin/refactor-some-builder-parts
[builder] cleanup env dispatcher and Builder.build()
Upstream-commit: d2ab40e5b99bc2ab0abfea146544a20ce6081942
Component: engine
2017-04-12 11:11:06 -07:00
b2a8f5ff5d Merge pull request #32506 from cpuguy83/cancellable_route
Use function arguments for route setup.
Upstream-commit: 480d1b841fd238788b75f31cd8ebe0b3a84f8eec
Component: engine
2017-04-12 14:10:50 -04:00
866adfbbee Merge pull request #28923 from erikh/fix-copy
Fix copy API (`docker cp`, etc) uid/gid handling
Upstream-commit: d40a17ffc2f6592396a3dfc0f5ebe396c2107536
Component: engine
2017-04-12 08:21:17 -07:00
5f2d4821df Merge pull request #32481 from yongtang/30740-docs-prune-label
Update docs of `label` filter for `docker system prune`
Upstream-commit: d0bd5aa2a7ad2561f067a0b9e470fc51ac2874a3
Component: engine
2017-04-12 15:37:04 +02:00
2c970161a0 Use function arguments for route setup.
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 08a39d7f02c526767072b08587a539f8d8a20bd4
Component: engine
2017-04-12 08:43:51 -04:00
1386ad9dee daemon/archive.go: Fix copy routines to preserve UID.
This changes the long-standing bug of copy operations not preserving the
UID/GID information after the files arrive to the container.

Signed-off-by: Erik Hollensbe <github@hollensbe.org>
Upstream-commit: 8a7ff5ff746a77e0be601c11540562341b2228c1
Component: engine
2017-04-12 10:33:19 +00:00
b94b999d77 Merge pull request #32030 from ehazlett/any-runtime
Support Swarmkit Generic Task Runtime
Upstream-commit: 3343653edb9a9c152c043de577effda1d528d6c0
Component: engine
2017-04-11 17:53:20 -07:00
8df974860d Update docs of label filter for docker system prune
This fix updates docs of `label` filter for `docker system prune`.

This fix is related to #30740 and #29999, and specifically to comment
https://github.com/docker/docker/pull/30740#issuecomment-293012957.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 5b0ab45a1ef2ce52e78851f49a8390263e642263
Component: engine
2017-04-11 12:08:55 -07:00
a00fca972d Remove unused id field from Builder.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: a6abd57b83dc0aaf0cedeeb488c8a41262e46b7d
Component: engine
2017-04-11 14:44:32 -04:00
e5fb241134 bump API and version
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
Upstream-commit: b507158c0f0c6cbee52d3ff7e0278004d3486c9d
Component: engine
2017-04-11 11:21:55 -07:00
f0e93c44da updated swagger with new fields for task spec
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
Upstream-commit: d6bb4ae434b9737fc392f98130b0be3d632d6bdc
Component: engine
2017-04-11 14:02:02 -04:00
26d7ec7da8 return exec.Controller instead of nil
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
Upstream-commit: 3a9be929272d089d57745350b8888760a18b2526
Component: engine
2017-04-11 14:02:02 -04:00
5d661a7bc0 add support for swarmkit generic runtime
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
Upstream-commit: e06e2ef107ad09191bfea3dfe51cfa830114b54b
Component: engine
2017-04-11 14:02:01 -04:00
d2aa64e45c Merge pull request #32284 from aaronlehmann/fix-service-defaults
Improve default handling for "service create"
Upstream-commit: a258ef58d8a100467d5d948b026a884ebe58eaf4
Component: engine
2017-04-11 13:06:53 +02:00
0bf5e70579 Merge pull request #32496 from tonistiigi/build-target
builder: add an option for specifying build target
Upstream-commit: 18ae574cab9c4eb5183e419b1ca698dd76ed1194
Component: engine
2017-04-10 19:02:21 -07:00
108aa4253e Merge pull request #32462 from dperny/service-logs-general-availability
Remove experimental from service logs
Upstream-commit: 17a3e4511d8f20868a051f10dbedabdce7ea2f9c
Component: engine
2017-04-10 18:30:20 -07:00
a89a2c21c5 builder: add an option for specifying build target
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 33e07f41adc0ec96edad5f22bc2cfaec0d26ea58
Component: engine
2017-04-10 16:21:43 -07:00
3d267a0dc8 Change "service inspect" to show defaults in place of empty fields
This adds a new parameter insertDefaults to /services/{id}. When this is
set, an empty field (such as UpdateConfig) will be populated with
default values in the API response. Make "service inspect" use this, so
that empty fields do not result in missing information when inspecting a
service.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 1d274e9acfe96b98be3ec956636ff4e5c70e98af
Component: engine
2017-04-10 13:41:16 -07:00
24a0a6b6bb Remove experimental from service logs
Service logs API is now stable. Service logs now support all features,
except retrieving details provided to the log driver.

Signed-off-by: Drew Erny <drew.erny@docker.com>
Upstream-commit: 306cfecc8c146ea8addb44dd35296808b25916a2
Component: engine
2017-04-10 13:40:45 -07:00
ef02a743db Merge pull request #28403 from cpuguy83/logging_plugins
Implement plugins for logging drivers
Upstream-commit: 28334c1d829b9ea8ac7e10d45a6db37c3821d5db
Component: engine
2017-04-10 21:57:56 +02:00
6d75b7a10d Merge pull request #30740 from yongtang/29999-prune-filter-label
Add `label` filter for `docker system prune`
Upstream-commit: 4460312ce1a53316e3c474ab951b85e737a902c5
Component: engine
2017-04-10 19:38:01 +02:00
276ea6a456 Implement plugins for logging drivers
Logging plugins use the same HTTP interface as other plugins for basic
command operations meanwhile actual logging operations are handled (on
Unix) via a fifo.

The plugin interface looks like so:

```go
type loggingPlugin interface {
  StartLogging(fifoPath string, loggingContext Context) error
  StopLogging(fifoPath)
```

This means a plugin must implement `LoggingDriver.StartLogging` and
`LoggingDriver.StopLogging` endpoints and be able to consume the passed
in fifo.

Logs are sent via stream encoder to the fifo encoded with protobuf.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 27bd6842f8518780b99fdb42f8e7f84c17856d87
Component: engine
2017-04-10 13:17:20 -04:00
98984ecab4 add status code 400 for update endpoints in swagger.yml
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: c284e85f590bcd7027cbb8e7077896df7ff6900c
Component: engine
2017-04-10 15:13:56 +08:00
137edd889c Merge pull request #32339 from aluzzardi/selinux
services: Add support for Credential Spec and SELinux
Upstream-commit: 091b5e68ea735bf4e8ece708bbc8c413a32eab73
Component: engine
2017-04-08 01:37:17 +02:00
ddc6479238 Merge pull request #32154 from dperny/refactor-logs
Refactor logs and support service logs with TTY 
Upstream-commit: 4a1a64c67768d6fbcf20a1b37ee58212b7e870c6
Component: engine
2017-04-07 18:06:50 -04:00
e41369fcc4 services: Add support for Credential Spec and SELinux
- Defined "normalized" type for Credential Spec and SELinux
- Added --credential-spec to docker service create & update
- SELinux is API only at the time

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Upstream-commit: 89a995a9d77cc4f95a29579e0a2b12cb3d805749
Component: engine
2017-04-07 11:30:54 -07:00
14ad9e03e4 add hosts example for serviceSpec in swagger.yml
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 412099baa9605149f58d1fe442a80c67bf7e3baa
Component: engine
2017-04-07 17:06:52 +08:00
334f054f13 refactor logs and support service logs /w tty
Refactor container logs system to make communicating log messages
internally much simpler. Move responsibility for marshalling log
messages into the REST server. Support TTY logs. Pave the way for fixing
the ambiguous bytestream format. Pave the way for fixing details.

Signed-off-by: Drew Erny <drew.erny@docker.com>
Upstream-commit: 1044093bb0aa12eb8972361a93b9bc8c4ddd857b
Component: engine
2017-04-06 17:54:11 -07:00
1623433ab1 Add support for update order
This parameter controls the order of operations when rolling out an
update task. Either the old task is stopped before starting the new one,
or the new task is started first, and the running tasks will briefly
overlap.

This commit adds Rollout to the API, and --update-order / --rollback-order
flags to the CLI.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 9b54994a8ada6ae15a4d2c3b925568e2061200ad
Component: engine
2017-04-06 17:23:36 -07:00
6469db0655 Merge pull request #32391 from aaronlehmann/no-stack-traces
api: Don't include stack traces with errors
Upstream-commit: 106a9a7d72427e9ceb6ca96bce6d96f6c822ce1c
Component: engine
2017-04-06 13:10:34 -07:00
83d9648a45 Add label filter for docker system prune
This fix tries to address the issue raised in 29999 where it was not
possible to mask these items (like important non-removable stuff)
from `docker system prune`.

This fix adds `label` and `label!` field for `--filter` in `system prune`,
so that it is possible to selectively prune items like:
```
$ docker container prune --filter label=foo

$ docker container prune --filter label!=bar
```

Additional unit tests and integration tests have been added.

This fix fixes 29999.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 702524732427ce028277f99f215e1fab297e6001
Component: engine
2017-04-06 09:11:25 -07:00
e25f6c5a1b Added start period option to health check.
Signed-off-by: Elias Faxö <elias.faxo@gmail.com>
Upstream-commit: e401f63735d8ebcff387c571d1f61ce52bdea86e
Component: engine
2017-04-06 12:35:34 +02:00
75b06f1d80 api: Don't include stack traces with errors
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 7381fffb2f0a0307ef1575a299028d036f24088f
Component: engine
2017-04-05 18:13:58 -07:00
ac33a30857 Merge pull request #32015 from dperny/service-logs-support-task-logs
Add Support for Service Task Logs
Upstream-commit: 170be9c26745b953dbfc5cafdc63eb3895c2c541
Component: engine
2017-04-04 00:15:13 -07:00
93e346635c Add support for task and arbitrary combo logs
Refactored the API to more easily accept new endpoints. Added REST,
client, and CLI endpoints for getting logs from a specific task. All
that is needed after this commit to enable arbitrary service log
selectors is a REST endpoint and handler.

Task logs can be retrieved by putting in a task ID at the CLI instead of
a service ID.

Signed-off-by: Drew Erny <drew.erny@docker.com>
Upstream-commit: d330dc3223df7e6c2b066373718709e34e19efca
Component: engine
2017-04-03 18:40:54 -07:00
694fa58dc1 Merge pull request #31889 from cpuguy83/all_the_pprof
Use generic handler for pprof profile lookups
Upstream-commit: 022552ac873939db018722cb4a2e8289c6927e5e
Component: engine
2017-04-03 15:14:12 +02:00
e0362b90f0 Merge pull request #31022 from jmzwcn/issue30994
docker version output is not consistent when there are downgrades or incompatibilities #30994
Upstream-commit: 3dfce9fbb813511a0dbfea1fa3bc80a37e7072c4
Component: engine
2017-03-31 15:55:03 -07:00
2fe955c1d1 Merge pull request #31634 from AkihiroSuda/clarify-env-without-value
api: clarify that Env var without `=` is removed from the environment
Upstream-commit: 9f9cc221bdb0a919d6ed28bdfaffa9ae2fe3a5fd
Component: engine
2017-03-31 17:34:32 +02:00
2fba778d82 Docker version output is not consistent when there are downgrades or incompatibilities.
Signed-off-by: Daniel Zhang <jmzwcn@gmail.com>
Upstream-commit: 50aa1e5b2819ea739beaa58bfe7836c2c8b4b9ff
Component: engine
2017-03-29 21:53:19 +08:00
65370eec05 api: Omit Cluster, Nodes, and Managers from swarm info when unavailable
Currently these fields are included in the response JSON with zero
values. It's better not to include them if the information is
unavailable (for example, on a worker node).

This turns Cluster into a pointer so that it can be left out.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 3894254dddc56bf283d7361dc88953a167a3be1f
Component: engine
2017-03-28 14:20:25 -07:00
b8233dd3d5 Merge pull request #30810 from allencloud/make-secret-ls-support-filter
make secret ls support filters in CLI
Upstream-commit: 4df350b8c7a53dc82d8a6e187882faf8f90ce766
Component: engine
2017-03-28 13:43:19 +02:00
723b938620 Merge pull request #32107 from mkumatag/fix_api_doc
Fix Healthcheck API doc
Upstream-commit: abecc530ee28ca4accb295c83f762855732d2667
Component: engine
2017-03-27 18:45:48 +02:00
0bc9fdd1d1 make secret ls support filters in CLI
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 3935074016697b14023371b84b68c62fa1f3344e
Component: engine
2017-03-27 10:16:45 +08:00
d79afa43f8 Allow user to modify ingress network
Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: d59d19c32818ed73cc6b4d153f2858c4fe97f50e
Component: engine
2017-03-26 15:46:18 -07:00
7006be9c48 Fix Healthcheck API doc
Signed-off-by: Manjunath A Kumatagi <mkumatag@in.ibm.com>
Upstream-commit: 4df54695ef12fa0ba474b571771ed09232ad00ba
Component: engine
2017-03-26 08:45:11 -04:00
d918c4ba81 Add --filter scope=swarm|local for docker network ls
This fix tries to address the request in 31324 by adding
`--filter scope=swarm|local` for `docker network ls`.

As `docker network ls` has a `SCOPE` column by default,
it is natural to add the support of `--filter scope=swarm|local`.

This fix adds the `scope=swarm|local` support for
`docker network ls --filter`.

Related docs has been updated.

Additional unit test cases have been added.

This fix fixes 31324.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 704ea8f6b4ad6f43c348affe357994d440aaf3de
Component: engine
2017-03-23 18:48:11 -07:00
ed9e56a592 Merge pull request #31715 from anusha-ragunathan/ipc-host
Add support in plugin config for accessing host ipc and pid namespace.
Upstream-commit: 0caced4644c0b188b9644e9ab5fe7a31ac855968
Component: engine
2017-03-22 14:17:21 -07:00
e82f1456b4 Embed DockerVersion in plugin config.
Embedding DockerVersion in plugin config when the plugin is created,
enables users to do a docker plugin inspect and know which version
the plugin was built on. This is helpful in cases where users are
running a new plugin on older docker releases and confused at
unexpected behavior.

By embedding DockerVersion in the config, we claim that there's no
guarantee that if the plugin config's DockerVersion is greater that
the version of the docker engine the plugin is executed against, the
plugin will work as expected.

For example, lets say:
- in 17.03, a plugin was released as johndoe/foo:v1
- in 17.05, the plugin uses the new ipchost config setting and author
publishes johndoe/foo:v2

In this case, johndoe/foo:v2 was built on 17.05 using ipchost, but is
running on docker-engine version 17.03. Since 17.05 > 17.03, there's
no guarantee that the plugin will work as expected. Ofcourse, if the
plugin did not use newly added config settings (ipchost in this case)
in 17.05, it would work fine in 17.03.

Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
Upstream-commit: 342ed107bc6283cfc9b3301142e71f20aae0aaca
Component: engine
2017-03-22 10:26:20 -07:00