Commit Graph

2905 Commits

Author SHA1 Message Date
e529bcd027 Implement incremental file sync using client session
Also exposes shared cache and garbage collection/prune
for the source data.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 5c3d2d552b0430672d5f481ab2d37036f6e92166
Component: engine
2017-06-22 11:52:35 -07:00
6553b6419b session: update swagger yaml
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 4f51ca1e825072d89762a1a5273e714196910d90
Component: engine
2017-06-22 11:22:42 -07:00
b1e4d7d884 Add long-running client session endpoint
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: ec7b6238c31e26702ecf366731532e189b5da142
Component: engine
2017-06-22 11:22:41 -07:00
ad62bca460 Merge pull request #33241 from Microsoft/jjh/multi-layerstore
LCOW: Support most operations excluding remote filesystem
Upstream-commit: 930e6896685f614d8f15ed10207596b1a151cbc8
Component: engine
2017-06-21 15:45:23 -07:00
01b491fce5 LCOW: Create layer folders with correct ACL
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: ed10ac6ee93cf5c389a735c0c97b08d5d5dff3a9
Component: engine
2017-06-20 19:50:12 -07:00
9541d17c29 LCOW: Plumb through platform on Import
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 3d5cec70b4432866e4c290e9fc601571ca09da9d
Component: engine
2017-06-20 19:49:54 -07:00
2665467b29 LCOW: Builder plumbing
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 08252bc963a20b2fb3052fc8db7143771c8c3248
Component: engine
2017-06-20 19:49:53 -07:00
094f300460 LCOW: pull goes to correct stores
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: a1fe1dc791633998bcc82b5f0734a5da68d2bb41
Component: engine
2017-06-20 19:49:52 -07:00
3af9801344 LCOW: Move daemon stores to per platform
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 3aa4a0071536d3b106374eaa44d8a55765901aa6
Component: engine
2017-06-20 19:49:52 -07:00
d3db128900 builder: fix copy —from conflict with force pull
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: c268d9da4b658b2dd1fe48010a8929b603913e92
Component: engine
2017-06-20 15:45:33 -07:00
8c7c972d20 Merge pull request #33454 from dnephin/refactor-builder-remove-copy-on-build
[Builder] Move file coping from the daemon to the builder
Upstream-commit: 99c72eb2682c0539ad3cc544eb28876af78b33a1
Component: engine
2017-06-20 10:12:57 +02:00
c832750e54 Remove Go 1.6 code from moby
Signed-off-by: Boaz Shuster <ripcurld.github@gmail.com>
Upstream-commit: 6bfd0f6b5d08bcd609da11947432ad0f3aa3d8fd
Component: engine
2017-06-19 15:59:00 +03:00
b687d7ca5a Merge pull request #33630 from yongtang/167-cli-network-inspect-scope
Add `scope` filter in `GET /networks/(id or name)`
Upstream-commit: 4310f7da7e6bcd8185bf05e032f9b7321cfa6ea2
Component: engine
2017-06-12 18:27:24 -07:00
2ef8445394 Merge pull request #33005 from alfred-landrum/denied-error
Suggest login on pull denial
Upstream-commit: f4bf61c79da153c039e2df586737cd8d54d26a55
Component: engine
2017-06-13 01:51:18 +02:00
99aad7f08b Add scope filter in /networks/<id>
This fix tries to add a `scope` in the query of `/networks/<id>`
(`NetworkInspect`) so that in case of duplicate network names,
it is possible to locate the network ID based on the network
scope (`local`, 'swarm', or `global`).

Multiple networks might exist in different scopes, which is a legitimate case.
For example, a network name `foo` might exists locally and in swarm network.

However, before this PR it was not possible to query a network name `foo`
in a specific scope like swarm.

This fix fixes the issue by allowing a `scope` query in `/networks/<id>`.

Additional test cases have been added to unit tests and integration tests.

This fix is related to docker/cli#167, moby/moby#30897, moby/moby#33561, moby/moby#30242

This fix fixes docker/cli#167

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 158b2a1875cf33f3560dedaeb0149e1fbe54c1ef
Component: engine
2017-06-12 09:54:25 -07:00
33135ac6fd Merge pull request #33612 from thaJeztah/bump-api-version
Bump API version
Upstream-commit: 3f6b6c2981aa231823c51ed84ee0f89d81105c5b
Component: engine
2017-06-10 02:00:45 +02:00
83a1ff66bd Suggest login on pull denial
Signed-off-by: Alfred Landrum <alfred.landrum@docker.com>
Upstream-commit: 8d9f51ea55c8c9373d20bcc7561ca34c59aaf8c2
Component: engine
2017-06-09 12:43:21 -07:00
c9920c89e8 Merge pull request #33609 from thaJeztah/backport-29418
backport #29418 "Fix buildIpamResources()" to master
Upstream-commit: c9f26eaaf8b9f7977319d6d596f8701bbc58a108
Component: engine
2017-06-09 19:18:50 +02:00
aed3533620 Bump API version
With the Moby/Docker split, no decisions have been
made yet how, and when to bump the API version.

Although these decisions should not be lead
by Docker releases, I'm bumping the API version
to not complicate things for now; after this bump
we should make a plan how to handle this in future
(for example, using SemVer for the REST api, and
bump with every change).

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 7839ff2244a7fcbac0882b1426bbd2c5477c1abe
Component: engine
2017-06-09 14:58:01 +02:00
ae3f3a569b Merge pull request #32122 from allencloud/choose-rpc-code-to-determine-status-code
choose rpc code to determine status code
Upstream-commit: 27ca921db1d2b4f19fa60a5d7994fec29fb2d025
Component: engine
2017-06-09 14:32:24 +02:00
758ca586cf Merge pull request #29418 from aboch/p66
[1.13.x] Fix buildIpamResources()
(cherry picked from commit 4d2be03b68dd54d8f2307e8b4178ad8ed8d5d343)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 27498a3c60018ea2880a18beec65710fd27971a7
Component: engine
2017-06-09 13:51:43 +02:00
13d2adae3f Fix copy when used with scratch and images with empty RootFS
Commit the rwLayer to get the correct DiffID
Refacator copy in thebuilder
move more code into exportImage
cleanup some windows tests
Release the newly commited layer.
Set the imageID on the buildStage after exporting a new image.
Move archiver to BuildManager.
Have ReleaseableLayer.Commit return a layer
and store the Image from exportImage in the local imageSources cache
Remove NewChild from image interface.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 51360965206b0db49cc0365dabb590063a17a9df
Component: engine
2017-06-08 15:07:16 -04:00
cc0cc953be Describe the differences between container-inspect and container-list
Signed-off-by: Boaz Shuster <ripcurld.github@gmail.com>
Upstream-commit: e8a1d99afb42d0931f7e1fd3df41611aafddf5a9
Component: engine
2017-06-06 21:33:08 +03:00
9244630a6b choose rpc code to determine status code
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: f257f77c6c13ee851d3b899f8d51628a5dec92db
Component: engine
2017-06-06 10:08:50 +08:00
dbc4b6c5bd Do not log the CA config CA signing key in debug mode.
Signed-off-by: Ying Li <ying.li@docker.com>
Upstream-commit: d60f18204978d438d1eb336512576d47991c8ac1
Component: engine
2017-05-31 18:15:33 -07:00
bad34014ad Merge pull request #33423 from gesellix/swagger-docs-typo
Fix typo in swagger doc
Upstream-commit: d192db0d9350222d2b8bb6eba8525b04c3be7d61
Component: engine
2017-05-29 15:58:50 +02:00
7acd97d8f9 Merge pull request #33257 from mtesselH/master
Add CreatedAt filed to volume. Display when volume is inspected.
Upstream-commit: 79b19c2e16c43f22187538953f49b2c048b063f8
Component: engine
2017-05-29 10:48:07 +01:00
1a6d5b7b4c Fix typo in swagger doc
Signed-off-by: Tobias Gesellchen <tobias@gesellix.de>
Upstream-commit: 56da4f2fb2509f9b2c2bc1c1c609c1dabeaec07d
Component: engine
2017-05-27 22:37:36 +02:00
3d97792442 Add CreatedAt filed to volume. Display when volume is inspected.
Closes #32663 by adding CreatedAt field when volume is created.
Displaying CreatedAt value when volume is inspected
Adding tests to verfiy the new field is correctly populated

Signed-off-by: Marianna <mtesselh@gmail.com>

Moving CreatedAt tests from the CLI

Moving the tests added for the newly added CreatedAt field for Volume, from CLI to API tests

Signed-off-by: Marianna <mtesselh@gmail.com>
Upstream-commit: a46f757c4043031379362c5d6b3bad7562ab9fed
Component: engine
2017-05-26 11:47:02 -07:00
cc72dd2445 Stop referring CLI flags in error messages if API client is unknown
Signed-off-by: Stanislav Bondarenko <stanislav.bondarenko@gmail.com>
Upstream-commit: 92291a7355dff35be70b5d0ebf634f0232ca6a94
Component: engine
2017-05-22 18:50:49 -04:00
c9ec562bee remove RuntimeData from cluster and types
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
Upstream-commit: 8eeba751983d6499a07fcd21c26f381eb1d17d19
Component: engine
2017-05-19 17:10:32 -04:00
ddd4203548 Merge pull request #33261 from aaronlehmann/empty-platform
api: Only return a Platform when relevant information is available
Upstream-commit: f888a25ff5bc9bb7c95400ec19b9a5fa0d738bab
Component: engine
2017-05-19 20:05:07 +02:00
4bffda81c9 Improve description of Running and Paused booleans
Commit abd72d4008dde7ee8249170d49eb4bc963c51e24 added
a "FIXME" comment to the container "State", mentioning
that a container cannot be both "Running" and "Paused".

This comment was incorrect, because containers on
Linux actually _must_ be running in order to be
paused.

This patch adds additional information both in a
comment, and in the API documentation to clarify
that these booleans are not mutually exclusive.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: b654b6244d6d63a0758029488a95feb446e089bd
Component: engine
2017-05-19 12:29:54 +02:00
cee45f7710 Adding network specific options to service create/update
The commit adds capability to accept csv parameters
for network option in service create/update commands.The change
includes name,alias driver options specific to the network.
With this the following will be supported

docker service create --name web --network name=docknet,alias=web1,driver-opt=field1=value1 nginx
docker service create --name web --network docknet nginx
docker service update web --network-add name=docknet,alias=web1,driver-opt=field1=value1
docker service update web --network-rm docknet

Signed-off-by: Abhinandan Prativadi <abhi@docker.com>
Upstream-commit: fe11de01772ec7c7501d3b679ce94d41bcc14060
Component: engine
2017-05-17 18:46:34 -07:00
f4e4bf60ab api: Only return a Platform when relevant information is available
I noticed that we could return a Platform that has no information filled
in. This doesn't look like it would cause any problems, but it would be
confusing. Fix the handler to only append to this slice when the
Platform is not empty.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: df86a14af21539422f667ae33601a4f24f21e574
Component: engine
2017-05-17 18:42:16 -07:00
4f94cc50a4 Integrate local datascope network with swarm
Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: b34d3e730fe3eee4b058e4dc165a7d4964e00a2a
Component: engine
2017-05-17 15:50:28 -07:00
eefcf59562 Allow to control network scope
- User can now promote a network's scope to swarm,
  so that the network is visible to swarm

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: fcafc7108b7b7f2ca9c2982b29b47de424f2da52
Component: engine
2017-05-17 15:50:28 -07:00
9f01da606a Support configuration networks
- They are configuration-only networks which
  can be used to supply the configuration
  when creating regular networks.
- They do not get allocated and do net get plumbed.
  Drivers do not get to know about them.
- They can be removed, once no other network is
  using them.
- When user creates a network specifying a
  configuration network for the config, no
  other network specific configuration field
  is are accepted. User can only specify
  network operator fields (attachable, internal,...)

Signed-off-by: Alessandro Boch <aboch@docker.com>
Upstream-commit: 9ee7b4dda926a1444dc0ea50c4ca6d90c8684060
Component: engine
2017-05-17 15:50:28 -07:00
5f22605796 support cluster events
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
Upstream-commit: 59d45c384a2de7bca73296ce1471646db14cb0c8
Component: engine
2017-05-17 11:46:30 -07:00
774fa5cacd Merge pull request #33237 from aaronlehmann/oci-types
api: Use OCI types for Digest and Platform
Upstream-commit: 77c9728847358a3ed3581d828fb0753017e1afd3
Component: engine
2017-05-17 02:40:11 +02:00
6f26254653 Merge pull request #32237 from jlhawn/update_container_wait
Update Container Wait
Upstream-commit: c053a2069e1c8e99488517071540fb3e526233f3
Component: engine
2017-05-17 02:39:52 +02:00
0e311d1c4e Merge pull request #33151 from nwt/push-foreign-layers
Add daemon option to push foreign layers
Upstream-commit: a30ef99e8dd2c3e7a54b6410a5709f61db59c07f
Component: engine
2017-05-17 02:04:31 +02:00
caabf0e2ac Merge pull request #32388 from nishanttotla/pin-by-digest-on-client-alternative
Moving docker service digest pinning to client side
Upstream-commit: d6f4fe9e38b60f63e429fff7ffced9c26cbf8236
Component: engine
2017-05-16 15:24:07 -07:00
fa44d02011 Update ContainerWait API
This patch adds the untilRemoved option to the ContainerWait API which
allows the client to wait until the container is not only exited but
also removed.

This patch also adds some more CLI integration tests for waiting for a
created container and waiting with the new --until-removed flag.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Handle detach sequence in CLI

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Update Container Wait Conditions

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Apply container wait changes to API 1.30

The set of changes to the containerWait API missed the cut for the
Docker 17.05 release (API version 1.29). This patch bumps the version
checks to use 1.30 instead.

This patch also makes a minor update to a testfile which was added to
the builder/dockerfile package.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Remove wait changes from CLI

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Address minor nits on wait changes

- Changed the name of the tty Proxy wrapper to `escapeProxy`
- Removed the unnecessary Error() method on container.State
- Fixes a typo in comment (repeated word)

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Use router.WithCancel in the containerWait handler

This handler previously added this functionality manually but now uses
the existing wrapper which does it for us.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Add WaitCondition constants to api/types/container

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Address more ContainerWait review comments

- Update ContainerWait backend interface to not return pointer values
  for container.StateStatus type.
- Updated container state's Wait() method comments to clarify that a
  context MUST be used for cancelling the request, setting timeouts,
  and to avoid goroutine leaks.
- Removed unnecessary buffering when making channels in the client's
  ContainerWait methods.
- Renamed result and error channels in client's ContainerWait methods
  to clarify that only a single result or error value would be sent
  on the channel.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Move container.WaitCondition type to separate file

... to avoid conflict with swagger-generated code for API response

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Address more ContainerWait review comments

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: 4921171587c09d0fcd8086a62a25813332f44112
Component: engine
2017-05-16 15:11:39 -07:00
3f22cbeb2a Update Container Wait Backend
This patch consolidates the two WaitStop and WaitWithContext methods
on the container.State type. Now there is a single method, Wait, which
takes a context and a bool specifying whether to wait for not just a
container exit but also removal.

The behavior has been changed slightly so that a wait call during a
Created state will not return immediately but instead wait for the
container to be started and then exited.

The interface has been changed to no longer block, but instead returns
a channel on which the caller can receive a *StateStatus value which
indicates the ExitCode or an error if there was one (like a context
timeout or state transition error).

These changes have been propagated through the rest of the deamon to
preserve all other existing behavior.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: cfdf84d5d04c8ee656e5c4ad3db993c258e52674
Component: engine
2017-05-16 15:09:14 -07:00
a57be1e4d4 api: Use OCI types for Digest and Platform
The current use of the types from distribution brings in some
unfortunate dependencies, including other distribution packages and the
gorilla/mux and gorilla/context packages. Using the OCI types avoids
the extra dependencies for client users.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 309f99edae5849327ab9c3ec9335b42ba5612202
Component: engine
2017-05-16 14:54:23 -07:00
67b57727bd Add daemon option to push foreign layers
The --allow-nondistributable-artifacts daemon option specifies
registries to which foreign layers should be pushed.  (By default,
foreign layers are not pushed to registries.)

Additionally, to make this option effective, foreign layers are now
pulled from the registry if possible, falling back to the URLs in the
image manifest otherwise.

This option is useful when pushing images containing foreign layers to a
registry on an air-gapped network so hosts on that network can pull the
images without connecting to another server.

Signed-off-by: Noah Treuhaft <noah.treuhaft@docker.com>
Upstream-commit: 67fdf574d5acd6ddccb6ece0ffe0ace1c1608712
Component: engine
2017-05-16 14:36:36 -07:00
4dacea7efb Merge pull request #33144 from nishanttotla/update-swarmkit-platform-structs
Adding Platforms field to TaskSpec Placement
Upstream-commit: 7b7f9a481e21e740263cb43baae9473d888afcba
Component: engine
2017-05-16 15:22:03 -04:00
6b1b90eeb8 Disabling digest pinning for API versions < 1.30
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
Upstream-commit: c0afd9c873183604e57282e1cf47605c1f1e4d43
Component: engine
2017-05-15 16:42:43 -07:00
6b46f385fc Moving docker service digest pinning to client side
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
Upstream-commit: c1635c1ae3459e41fea3adb8188d9b3ce94f21a0
Component: engine
2017-05-15 16:42:43 -07:00