Commit Graph

30787 Commits

Author SHA1 Message Date
dbe03d4016 Changing the get network request to return swarm scope predefined networks
Starting 17.06 swarm service create supports service creates with predefined
networks like host and bridge. Due to the nature of the feature, swarm manager
has a swarm scope predefined networks in addition to local scoped
predefined networks on all nodes. However network inspects for swarm scoped
predefined networks was not possible. The fix adds support for network inspect
for swarm scoped predefined networks.

Signed-off-by: Abhinandan Prativadi <abhi@docker.com>
(cherry picked from commit 5bfefb2d3662fa066ddf0d0e10cac93ee70f7ae8)
Signed-off-by: Abhinandan Prativadi <abhi@docker.com>
2017-08-01 08:45:51 -07:00
c257617b99 Merge pull request #118 from andrewhsu/rc1
bump version to 17.06.1-ce-rc1
2017-07-13 16:03:01 -07:00
06f434c72b Merge pull request #108 from andrewhsu/fix-load-image
[17.06] backport fix "Stop trying to load images on an incompatible OS"
2017-07-13 12:04:27 -07:00
1d1b9ad4db Merge pull request #115 from andrewhsu/set-ping-ver
[17.06] Set ping version even on error
2017-07-13 11:59:16 -07:00
ab734f59cc Merge pull request #105 from andrewhsu/backport-doc-fixes
[17.06] backport various docs fixes
2017-07-13 11:54:25 -07:00
b538302e2c Merge pull request #90 from andrewhsu/fix-leak
[17.06] Prevent a goroutine leak when healthcheck gets stopped
2017-07-13 13:58:07 +02:00
021cd82205 import runtime so cherry-pick moby/moby@b9255e4 can work
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-13 04:26:09 +00:00
10aa812ef5 Set ping version even on error
In some cases a server may return an error on the ping response but
still provide version details. The client should use these values when
available.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit 27ef09a46ffeb8ba42548de937b68351009f30ea)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-13 03:55:49 +00:00
fb319d1554 Merge pull request #114 from cyli/re-vendor-swarmkit
[17.06] backport (swarmkit) cluster update and memory issue fixes
2017-07-12 17:34:49 -07:00
31875af469 adjust cherry-pick moby/moby@b9255e4 to work without lcow
Because the LCOW support is not part of this codebase, removing the
lines that expect it to be there.

Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-12 22:56:09 +00:00
136b90fbd0 Merge pull request #102 from tiborvass/runtime-spec-fix
[17.06][engine][vendor] forks of containerd + runc + runtime-spec
2017-07-12 15:29:33 -07:00
9241ec7a1e Bump swarmkit vendor in order to include the following changes:
- https://github.com/docker/swarmkit/pull/2281 - fixes an issue where some cluster updates
  could be missed if a manager receives a catch-up snapshot from another manager
- https://github.com/docker/swarmkit/pull/2300 - fixes a possible memory issue if an
  external CA sends an overlarge response

Signed-off-by: Ying <ying.li@docker.com>
2017-07-12 14:50:21 -07:00
aaf863d88a Merge pull request #100 from andrewhsu/fix-build-git
[17.06] Fix handling of remote "git@" notation
2017-07-12 14:43:27 -07:00
2d8beb7256 Merge pull request #95 from andrewhsu/fix-logging
[17.06] Fix stderr logging for journald and syslog
2017-07-12 14:40:48 -07:00
7a50b06fea Merge pull request #99 from andrewhsu/redact
[17.06] middleware: Redact secret data on "secret create"
2017-07-12 14:37:44 -07:00
2e99eed6f1 Merge pull request #89 from tonistiigi/fix-add-remote
[17.06] build: fix add from remote url
2017-07-12 10:38:32 -07:00
cb9b544edf Merge pull request #107 from andrewhsu/fix-service-spec
[17.06] backport "Do not add duplicate platform information to service spec"
2017-07-12 10:35:50 -07:00
dfe4a1d9f2 Stop trying to load images on an incompatible OS
Signed-off-by: John Stephens <johnstep@docker.com>
(cherry picked from commit b9255e4a531d2ad0239481eba2a635f7d48718fb)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-12 04:33:36 +00:00
abfc72adff Merge pull request #92 from andrewhsu/fix-relabel
[17.06] Do not error on relabel when relabel not supported
2017-07-11 21:29:47 -07:00
b5f090a4fe Merge pull request #113 from andrewhsu/optimize-dockerfile
[17.06] Remove OSX cross stuff from main Dockerfile
2017-07-11 21:25:42 -07:00
2206628703 [engine][vendor] forks of containerd + runc + runtime-spec
This vendors from the docker org:
- containerd to 6e23458c129b551d5c9871e5174f6b1b7f6d1170
- runc to 810190ceaa507aa2727d7ae6f4790c76ec150bd2
- runtime-spec to a45ba0989fc26c695fe166a49c45bb8b7618ab36

This fixes two issues:
- if the container is paused, it now responds properly to SIGKILL
- on buggy kernels such as RHEL7.2, a int64->uint64 conversion bug
  prevented containers to start when memory cgroup was specified.

Signed-off-by: Tibor Vass <tibor@docker.com>
2017-07-12 03:13:56 +00:00
0aba54445b Merge pull request #98 from andrewhsu/fix-log-readers
[17.06] Fix log readers can block writes indefinitely
2017-07-11 19:01:53 -07:00
75ef04b420 Merge pull request #94 from andrewhsu/fix-grpc
[17.06] Limit max backoff delay to 2 seconds for GRPC connection
2017-07-11 18:59:44 -07:00
5c477f0e07 Remove OSX cross stuff from main Dockerfile
This is no longer needed here. It was required for compiling the CLI
which we no longer do here.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit 57f0e0c61982269093eb6d9934656ea70b573938)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-12 01:52:53 +00:00
b0efd8dda5 Do not error on relabel when relabel not supported
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit ebfdfc5768b74e0a52875cf76a0576bfcd66445c)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-12 01:16:00 +00:00
7fe174d3f0 add go imports to enable specific cherry-pick of 913eb99
So that we don't have bring in the entire commit d3d1aab

Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 23:00:32 +00:00
425242f524 Fix handling of remote "git@" notation
`docker build` accepts remote repositories
using either the `git://` notation, or `git@`.

Docker attempted to parse both as an URL, however,
`git@` is not an URL, but an argument to `git clone`.

Go 1.7 silently ignored this, and managed to
extract the needed information from these
remotes, however, Go 1.8 does a more strict
validation, and invalidated these.

This patch adds a different path for `git@` remotes,
to prevent them from being handled as URL (and
invalidated).

A test is also added, because there were no
tests for handling of `git@` remotes.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 913eb99fdcd26a4106250bd40dfe8b9c18564b23)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 23:00:32 +00:00
78debca270 middleware: Redact secret data on "secret create"
With debug logging turned on, we currently log the base64-encoded secret
payload.

Change the middleware code to redact this. Since the field is called
"Data", it requires some context-sensitivity. The URI path is examined
to see which route is being invoked.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
(cherry picked from commit 3fbc352cbbce06cd3001d6b14b2b1ebcb4d42cd5)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 22:58:41 +00:00
bac91bd031 Fix stderr logging for journald and syslog
logger.PutMessage, added in #28762 (v17.04.0-ce), clears msg.Source. So journald
and syslog were treating stderr messages as if they were stdout.

Signed-off-by: David Glasser <glasser@davidglasser.net>
(cherry picked from commit 917050c5728f2fb9958ccb3ab66a23766f741adc)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 22:53:07 +00:00
371fed7778 Fix plugin remove dir name after rename.
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit 4bf263c19873718394f8161dbc020bf4be30f9d6)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 22:51:51 +00:00
3218b57038 import system for plugin/manager.go
To get the cherry-pick ba42966 to merge smoothly,
expecting import of system. The import of system was added by
https://github.com/docker/docker-ce/commit/8508f49 but not taking
entire commit.

Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 22:51:51 +00:00
73b8fa7bc6 Make plugin removes more resilient to failure
Before this patch, if the plugin's `config.json` is successfully removed
but the main plugin state dir could not be removed for some reason (e.g.
leaked mount), it will prevent the daemon from being able to be
restarted.

This patches changes this to atomically remove the plugin such that on
daemon restart we can detect that there was an error and re-try. It also
changes the logic so that it only logs errors on restore rather than
erroring out the daemon.

This also removes some code which is now duplicated elsewhere.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit 11cf394e5ea964636294a219872b188fe5bdf4dd)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 22:51:51 +00:00
4295f109dc Prevent a goroutine leak when healthcheck gets stopped
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
(cherry picked from commit 67297ba0051d39be544009ba76abea14bc0be8a4)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 22:49:56 +00:00
4ff90f5cb1 vndr to update vendor for github.com/spf13/cobra
No changes to vendor.conf, just running vndr.

Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 07:43:45 +00:00
af26684564 vndr to update vendor for github.com/Microsoft/go-winio
No changes to vendor.conf, just running vndr.

Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 07:41:38 +00:00
9abebe3dd0 Do not add duplicate platform information to service spec
Signed-off-by: Nishant Totla <nishanttotla@gmail.com>
(cherry picked from commit da85b62001ec390bdc30b321c4a5cd23c17eeb81)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 05:06:08 +00:00
149c1a0435 Fix api-version history
Commit c79c16910c0f3d6e88f2dc6ef609ecc3b02ccef9
inadvertently put these API changes under API 1.31,
but they were added in API 1.30.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit dd5e818fabc7edf7fa4d952e62b949b224909d2a)

Conflicts:
components/engine/docs/api/version-history.md
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 04:27:14 +00:00
2cf204719f Add missing API documentatoin for DataPathAddr
COmmit 0307fe1a0bcdc02583a24add41eb783c117bad8c added
a new `DataPathAddr` property to the swarm/init and swarm/join
endpoints. This property was not yet added to the
documentation.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit c79c16910c0f3d6e88f2dc6ef609ecc3b02ccef9)

Conflicts:
components/engine/docs/api/version-history.md
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-11 04:26:05 +00:00
728c4a5bfe use latestChunk instead of latestFile to get cherry-pick commit 7bd7bde working
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-07 18:31:52 +00:00
7bd7bdeada Fix log readers can block writes indefinitely
Before this patch, a log reader is able to block all log writes
indefinitely (and other operations) by simply opening the log stream and
not consuming all the messages.

The reason for this is we protect the read stream from corruption by
ensuring there are no new writes while the log stream is consumed (and
caught up with the live entries).

We can get around this issue because log files are append only, so we
can limit reads to only the section of the file that was written to when
the log stream was first requested.

Now logs are only blocked until all files are opened, rather than
streamed to the client.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit e2209185ed1c959131d4068ec7fc93e194dc0802)

Conflicts:
components/engine/daemon/logger/jsonfilelog/read.go
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-06 01:29:57 +00:00
dee078ae96 Remove docs (except docs/api), experimental/, contrib/completion, man/
They have been moved to github.com/docker/cli.

Signed-off-by: Tibor Vass <tibor@docker.com>
(cherry picked from commit b5579a4ce33af4c1f67118e11b5a01008a36d26a)

Conflicts:
components/engine/docs/extend/legacy_plugins.md
components/engine/docs/reference/builder.md
components/engine/docs/reference/commandline/node_ls.md
components/engine/docs/reference/commandline/run.md
components/engine/docs/reference/run.md
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-04 06:09:49 +00:00
fbc1b3070d Limit max backoff delay to 2 seconds for GRPC connection
Docker use default GRPC backoff strategy to reconnect to containerd when
connection is lost. and the delay time grows exponentially, until reaches 120s.

So Change the max delay time to 2s to avoid docker and containerd
connection failure.

Signed-off-by: Wentao Zhang <zhangwentao234@huawei.com>
(cherry picked from commit d3d8c77d195ce74f36ae6eee24578b9cac48f897)
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-04 03:39:09 +00:00
5595be60a5 bump version to 17.06.1-ce-rc1
Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
2017-07-04 03:34:58 +00:00
d0546cf484 build: fix add from remote url
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
(cherry picked from commit 2981667e11e24e9e1e61252a40ceb11fd7cb9811)
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-07-03 11:54:16 -07:00
f6937cf5b5 bump docker-ce VERSION to 17.06.0-ce
Signed-off-by: Eli Uriegas <eli.uriegas@docker.com>
2017-06-20 14:29:08 -07:00
b7e417335c Merge pull request #83 from seemethere/increment_rc5
bump VERSION to 17.06.0-ce-rc5
2017-06-19 23:57:57 -07:00
77c3cf33ae Merge pull request #85 from tiborvass/libnetwork-rc5
[engine] Vendor libnetwork to 20bf4e23da1bb3f9d3dc70e4cf531b84c45947bd
2017-06-19 20:56:21 -07:00
5578ebd2a2 [engine] Vendor libnetwork to 20bf4e23da1bb3f9d3dc70e4cf531b84c45947bd
Brings in this pull request:
- https://github.com/docker/libnetwork/pull/1808

Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-20 02:40:33 +00:00
bb23c93d28 Redact the swarm's spec's signing CA cert when getting swarm info, because
otherwise if the user gets the info from the API, makes a non-CA related change,
then updates, swarm will interpret this as the user trying to remove the signing
key from the swarm.  We are redacting due to usability reasons, not because
the signing cert is secret.  The signing KEY is secret, hence it's redacted.

Signed-off-by: Ying Li <ying.li@docker.com>
(cherry picked from commit bdfbd22afbbf16a07f0316656c6c17453df3e0f7)
Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-20 01:52:18 +00:00
073d80bc46 [engine] Vendor swarmkit to 9edb625cfb4407da456cc7fc479db6d824fe81f3
Brings in these pull requests:
- https://github.com/docker/swarmkit/pull/2224
- https://github.com/docker/swarmkit/pull/2268
- https://github.com/docker/swarmkit/pull/2263

Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-20 01:48:19 +00:00