Commit graph

45005 commits

Author SHA1 Message Date
Akihiro Suda
4d9cb4af16
Merge pull request #45709 from neersighted/check_config_bpf/23.0
[23.0 backport] contrib/check-config: require xt_bpf for encrypted overlay
2023-06-07 18:45:25 +09:00
Bjorn Neergaard
88049124e4
contrib/check-config: move xt_bpf check to overlay section
Signed-off-by: Bjorn Neergaard <bjorn.neergaard@docker.com>
(cherry picked from commit 800ea039ec)
Signed-off-by: Bjorn Neergaard <bjorn.neergaard@docker.com>
2023-06-06 16:49:26 -06:00
Bjorn Neergaard
028a8d421a
contrib/check-config: check for xt_bpf
We omit xt_u32 as it's optional; since we will remove support for this
module in the future, it's simpler to check for xt_bpf, which will
become the new baseline.

Related issues:
* https://github.com/microsoft/WSL/issues/10029#issuecomment-1574440255
* https://github.com/docker/for-win/issues/13450#issuecomment-1574443139

Signed-off-by: Bjorn Neergaard <bjorn.neergaard@docker.com>
(cherry picked from commit 1910fdde81)
Signed-off-by: Bjorn Neergaard <bjorn.neergaard@docker.com>
2023-06-06 16:49:24 -06:00
Sebastiaan van Stijn
57cc620aa0
Merge pull request #45638 from corhere/backport-23.0/libn/fix-encrypted-overlay-nonstandard-port
[23.0 backport] libnetwork/d/overlay: support encryption on any port
2023-05-27 00:44:51 +02:00
Cory Snider
f6ff82666d libn/d/overlay: support encryption on any port
While the VXLAN interface and the iptables rules to mark outgoing VXLAN
packets for encryption are configured to use the Swarm data path port,
the XFRM policies for actually applying the encryption are hardcoded to
match packets with destination port 4789/udp. Consequently, encrypted
overlay networks do not pass traffic when the Swarm is configured with
any other data path port: encryption is not applied to the outgoing
VXLAN packets and the destination host drops the received cleartext
packets. Use the configured data path port instead of hardcoding port
4789 in the XFRM policies.

Signed-off-by: Cory Snider <csnider@mirantis.com>
(cherry picked from commit 9a692a3802)
Signed-off-by: Cory Snider <csnider@mirantis.com>
2023-05-26 16:43:40 -04:00
Bjorn Neergaard
91cc8ad679
Merge pull request #45614 from thaJeztah/23.0_backport_skip_criu
[23.0 backport] Dockerfile: temporarily skip CRIU stage
2023-05-25 07:03:39 -06:00
Sebastiaan van Stijn
8a8f179a6a
Dockerfile: temporarily skip CRIU stage
The package repository currently has issues;

    => ERROR https://download.opensuse.org/repositories/devel:/tools:/criu/Debian_11/Release.key

The only test currently using this binary is currently skipped, as the test
was broken;
6e98a7f2c9/integration/container/checkpoint_test.go (L32-L33)

So let's disable this stage for the time being.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit d3d2823edf)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-25 12:20:50 +02:00
Sebastiaan van Stijn
fa97b40bc2
Merge pull request #45605 from neersighted/backport/45603/23.0
[23.0 backport] hack/make/.binary: don't use "netgo" when building Windows binaries
2023-05-24 21:28:33 +02:00
Sebastiaan van Stijn
c696fdd003
hack/make/.binary: don't use "netgo" when building Windows binaries
Starting with go1.19, the Go runtime on Windows now supports the `netgo` build-
flag to use a native Go DNS resolver. Prior to that version, the build-flag
only had an effect on non-Windows platforms. When using the `netgo` build-flag,
the Windows's host resolver is not used, and as a result, custom entries in
`etc/hosts` are ignored, which is a change in behavior from binaries compiled
with older versions of the Go runtime.

From the go1.19 release notes: https://go.dev/doc/go1.19#net

> Resolver.PreferGo is now implemented on Windows and Plan 9. It previously
> only worked on Unix platforms. Combined with Dialer.Resolver and Resolver.Dial,
> it's now possible to write portable programs and be in control of all DNS name
> lookups when dialing.
>
> The net package now has initial support for the netgo build tag on Windows.
> When used, the package uses the Go DNS client (as used by Resolver.PreferGo)
> instead of asking Windows for DNS results. The upstream DNS server it discovers
> from Windows may not yet be correct with complex system network configurations,
> however.

Our Windows binaries are compiled with the "static" (`make/binary-daemon`)
script, which has the `netgo` option set by default. This patch unsets the
`netgo` option when cross-compiling for Windows.

Co-authored-by: Bjorn Neergaard <bjorn.neergaard@docker.com>
Signed-off-by: Bjorn Neergaard <bjorn.neergaard@docker.com>
(cherry picked from commit 53d1b12bc0)
Signed-off-by: Bjorn Neergaard <bjorn.neergaard@docker.com>
2023-05-24 10:48:57 -06:00
Bjorn Neergaard
e017245c34
Merge pull request #45559 from crazy-max/23.0_backport_fix-worker-id
[23.0 backport] build: use daemon id as worker id for the graph driver controller
2023-05-19 09:44:25 -06:00
Bjorn Neergaard
56ece96655
Merge pull request #45569 from corhere/backport-23.0/fix-empty-container-decode
[23.0 backport] api/server: allow empty body for POST /commit again
2023-05-19 14:28:38 +01:00
Sebastiaan van Stijn
532f0bafb6
Merge pull request #45572 from thaJeztah/23.0_backport_fix_insecure_registries_reload
[23.0 backport] Fix insecure registries reload
2023-05-19 00:21:48 +02:00
Nolan Miles
0a24137a19
reorder load funcs to match newServiceConfig()'s order
Signed-off-by: Nolan Miles <nolanpmiles@gmail.com>
(cherry picked from commit f3645a2aa3)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-18 23:04:06 +02:00
Nolan Miles
7f9f2c67c4
add mirror to daemon reload test for insecure registries
Signed-off-by: Nolan Miles <nolanpmiles@gmail.com>
(cherry picked from commit 3b15156e4d)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-18 23:04:06 +02:00
Kevin Alvarez
276ef743cb
build: use daemon id as worker id for the graph driver controller
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
(cherry picked from commit 6d139e5e95)

# Conflicts:
#	builder/builder-next/controller.go
2023-05-18 22:22:23 +02:00
Cory Snider
6f7d702f9c api/server: allow empty body for POST /commit again
The error returned by DecodeConfig was changed in
b6d58d749c and caused this to regress.
Allow empty request bodies for this endpoint once again.

Signed-off-by: Cory Snider <csnider@mirantis.com>
(cherry picked from commit 967c7bc5d3)
Signed-off-by: Cory Snider <csnider@mirantis.com>
2023-05-18 16:11:33 -04:00
Akihiro Suda
cb3fd005d4
Merge pull request #45520 from thaJeztah/23.0_backport_vendor_distribution_v2.8.2
[23.0 backport] vendor: github.com/docker/distribution v2.8.2
2023-05-18 00:15:55 +09:00
Sebastiaan van Stijn
e94c22cc39
vendor: github.com/docker/distribution v2.8.2
CI

- Dockerfile: fix filenames of artifacts

Bugfixes

-  Fix panic in inmemory driver
-  Add code to handle pagination of parts. Fixes max layer size of 10GB bug
-  Parse http forbidden as denied
-  Revert "registry/client: set Accept: identity header when getting layers

Runtime

- Update to go1.19.9
- Dockerfile: update xx to v1.2.1 ([#3907](https://github.com/distribution/distribution/pull/3907))

Security

- Fix [CVE-2022-28391](https://www.cve.org/CVERecord?id=CVE-2022-28391) by bumping alpine from 3.14 to 3.16
- Fix [CVE-2023-2253](https://www.cve.org/CVERecord?id=CVE-2023-2253) runaway allocation on /v2/_catalog [`521ea3d9`](521ea3d973)

full diff: https://github.com/docker/distribution/compare/v2.8.1...v2.8.2

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

bump to release/2.8

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 7821d2d788)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-11 16:26:23 +02:00
Tianon Gravi
9dbdbd4b6d
Merge pull request #45371 from thaJeztah/23.0_backport_runc_binary_1.1.6
[23.0 backport] update runc binary to v1.1.7
2023-05-05 20:50:10 +00:00
Tianon Gravi
6030355735
Merge pull request #45478 from thaJeztah/23.0_containerd_binary_1.6.21
[23.0] update containerd binary to v1.6.21
2023-05-05 20:50:00 +00:00
Tianon Gravi
e1c053637b
Merge pull request #45477 from thaJeztah/23.0_backport_vendor_containerd_1.6.21
[23.0 backport] vendor: github.com/containerd/containerd v1.6.21
2023-05-05 20:43:10 +00:00
Sebastiaan van Stijn
e73310d8c9
update runc binary to v1.1.7
release notes: https://github.com/opencontainers/runc/releases/tag/v1.1.7
full diff: https://github.com/opencontainers/runc/compare/v1.1.6...v1.1.7

This is the seventh patch release in the 1.1.z release of runc, and is
the last planned release of the 1.1.z series. It contains a fix for
cgroup device rules with systemd when handling device rules for devices
that don't exist (though for devices whose drivers don't correctly
register themselves in the kernel -- such as the NVIDIA devices -- the
full fix only works with systemd v240+).

- When used with systemd v240+, systemd cgroup drivers no longer skip
  DeviceAllow rules if the device does not exist (a regression introduced
  in runc 1.1.3). This fix also reverts the workaround added in runc 1.1.5,
  removing an extra warning emitted by runc run/start.
- The source code now has a new file, runc.keyring, which contains the keys
  used to sign runc releases.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 2d0e899819)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:55:03 +02:00
Sebastiaan van Stijn
3f0402cb68
update runc binary to v1.1.6
release notes: https://github.com/opencontainers/runc/releases/tag/v1.1.6
full diff: https://github.com/opencontainers/runc/compare/v1.1.5...v1.1.6

This is the sixth patch release in the 1.1.z series of runc, which fixes
a series of cgroup-related issues.

Note that this release can no longer be built from sources using Go
1.16. Using a latest maintained Go 1.20.x or Go 1.19.x release is
recommended. Go 1.17 can still be used.

- systemd cgroup v1 and v2 drivers were deliberately ignoring UnitExist error
  from systemd while trying to create a systemd unit, which in some scenarios
  may result in a container not being added to the proper systemd unit and
  cgroup.
- systemd cgroup v2 driver was incorrectly translating cpuset range from spec's
  resources.cpu.cpus to systemd unit property (AllowedCPUs) in case of more
  than 8 CPUs, resulting in the wrong AllowedCPUs setting.
- systemd cgroup v1 driver was prefixing container's cgroup path with the path
  of PID 1 cgroup, resulting in inability to place PID 1 in a non-root cgroup.
- runc run/start may return "permission denied" error when starting a rootless
  container when the file to be executed does not have executable bit set for
  the user, not taking the CAP_DAC_OVERRIDE capability into account. This is
  a regression in runc 1.1.4, as well as in Go 1.20 and 1.20.1
- cgroup v1 drivers are now aware of misc controller.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit d0efca893b)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:54:45 +02:00
Sebastiaan van Stijn
edadebe177
update containerd binary to v1.6.21
release notes: https://github.com/containerd/containerd/releases/tag/v1.6.21

Notable Updates

- update runc binary to v1.1.7
- Remove entry for container from container store on error
- oci: partially restore comment on read-only mounts for uid/gid uses
- windows: Add ArgsEscaped support for CRI
- oci: Use WithReadonlyTempMount when adding users/groups
- archive: consistently respect value of WithSkipDockerManifest

full diff: https://github.com/containerd/containerd/compare/c0efc63d3907...v1.6.21

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:52:00 +02:00
Sebastiaan van Stijn
14661fc010
vendor: github.com/containerd/containerd v1.6.21
release notes: https://github.com/containerd/containerd/releases/tag/v1.6.21

Notable Updates

- update runc binary to v1.1.7
- Remove entry for container from container store on error
- oci: partially restore comment on read-only mounts for uid/gid uses
- windows: Add ArgsEscaped support for CRI
- oci: Use WithReadonlyTempMount when adding users/groups
- archive: consistently respect value of WithSkipDockerManifest

full diff: https://github.com/containerd/containerd/compare/c0efc63d3907...v1.6.21

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit a87313497b)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:21:51 +02:00
Djordje Lukic
e00f6efb20
Vendor containerd 1.6.x with the readonly mount fix
Uses containerd from release/1.6 commit c0efc63d39

Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
(cherry picked from commit be4abf9d6e)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:20:12 +02:00
Sebastiaan van Stijn
bd4620f6ee
vendor: github.com/containerd/containerd v1.6.20
full diff: https://github.com/containerd/containerd/compare/de33abf0547c...v1.6.20

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 61a0e79ad6)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:19:22 +02:00
Sebastiaan van Stijn
d06cf03729
vendor: re-vendor to add missing file
When running hack/vendor.sh, I noticed this file was added to vendor.
I suspect this should've been part of 0233029d5a,
but the vendor check doesn't appear to be catching this.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 3f09316e3b)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:16:49 +02:00
Sebastiaan van Stijn
cf7742ea7c
vendor: opencontainers/image-spec v1.1.0-rc2.0.20221005185240-3a7f492d3f1b
full diff: 02efb9a75e...3a7f492d3f

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 0233029d5a)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:15:35 +02:00
Sebastiaan van Stijn
382e9ebbf6
vendor: github.com/containerd/ttrpc v1.1.1
- server: Fix connection leak when receiving ECONNRESET

full diff: https://github.com/containerd/ttrpc/compare/v1.1.0...v1.1.1

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit c733cf223d)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:15:35 +02:00
Laura Brehm
e0843f264d
Update github.com/containerd/containerd to the HEAD of release/1.6 and vendor
Signed-off-by: Laura Brehm <laurabrehm@hey.com>
(cherry picked from commit e85c69e1b7)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-05 20:14:51 +02:00
Sebastiaan van Stijn
24fd7c5eb8
Merge pull request #45465 from corhere/backport-23.0/copy-xattr-notsupp
[23.0 backport] d/graphdriver/copy: support src fs w/o xattr support
2023-05-05 01:14:43 +02:00
Cory Snider
94fcd2d2ef d/graphdriver/copy: support src fs w/o xattr support
Treat copying extended attributes from a source filesystem which does
not support extended attributes as a no-op, same as if the file did not
possess the extended attribute. Only fail copying extended attributes if
the source file has the attribute and the destination filesystem does
not support xattrs.

Signed-off-by: Cory Snider <csnider@mirantis.com>
(cherry picked from commit 2b6761fd3e)
Signed-off-by: Cory Snider <csnider@mirantis.com>
2023-05-04 15:28:04 -04:00
Sebastiaan van Stijn
c5197fe6c5
Merge pull request #45455 from thaJeztah/23.0_update_go1.19.9
[23.0] update go to go1.19.9
2023-05-04 19:49:24 +02:00
Sebastiaan van Stijn
70dbd2c870
[23.0] update go to go1.19.9
go1.19.9 (released 2023-05-02) includes three security fixes to the html/template
package, as well as bug fixes to the compiler, the runtime, and the crypto/tls
and syscall packages. See the Go 1.19.9 milestone on our issue tracker for details.

https://github.com/golang/go/issues?q=milestone%3AGo1.19.9+label%3ACherryPickApproved

release notes: https://go.dev/doc/devel/release#go1.19.9
full diff: https://github.com/golang/go/compare/go1.19.8...go1.19.9

from the announcement:

> These minor releases include 3 security fixes following the security policy:
>
>- html/template: improper sanitization of CSS values
>
>   Angle brackets (`<>`) were not considered dangerous characters when inserted
>   into CSS contexts. Templates containing multiple actions separated by a '/'
>   character could result in unexpectedly closing the CSS context and allowing
>   for injection of unexpected HMTL, if executed with untrusted input.
>
>   Thanks to Juho Nurminen of Mattermost for reporting this issue.
>
>   This is CVE-2023-24539 and Go issue https://go.dev/issue/59720.
>
> - html/template: improper handling of JavaScript whitespace
>
>   Not all valid JavaScript whitespace characters were considered to be
>   whitespace. Templates containing whitespace characters outside of the character
>   set "\t\n\f\r\u0020\u2028\u2029" in JavaScript contexts that also contain
>   actions may not be properly sanitized during execution.
>
>   Thanks to Juho Nurminen of Mattermost for reporting this issue.
>
>   This is CVE-2023-24540 and Go issue https://go.dev/issue/59721.
>
> - html/template: improper handling of empty HTML attributes
>
>   Templates containing actions in unquoted HTML attributes (e.g. "attr={{.}}")
>   executed with empty input could result in output that would have unexpected
>   results when parsed due to HTML normalization rules. This may allow injection
>   of arbitrary attributes into tags.
>
>   Thanks to Juho Nurminen of Mattermost for reporting this issue.
>
>   This is CVE-2023-29400 and Go issue https://go.dev/issue/59722.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-05-03 20:48:31 +02:00
Sebastiaan van Stijn
94d3ad69cc
Merge pull request #45410 from rumpl/23.0_backport-fix-buildx-tag-events
[23.0 backport] Use the image service instead of the reference store for tagging
2023-04-26 17:29:05 +02:00
Sebastiaan van Stijn
933a9f83b7
Merge pull request #45407 from thaJeztah/23.0_backport_vendor_runc_1.1.5
[23.0 backport] vendor: github.com/opencontainers/runc v1.1.5
2023-04-26 16:43:32 +02:00
Djordje Lukic
fe0a414613
Use the image service instead of the reference store for tagging
The image store sends events when a new image is created/tagged, using
it instead of the reference store makes sure we send the "tag" event
when a new image is built using buildx.

Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
2023-04-26 16:32:25 +02:00
Sebastiaan van Stijn
1b1230eaaf
Merge pull request #45375 from thaJeztah/23.0_backport_bump_swarmkit
[23.0 backport] vendor: github.com/moby/swarmkit/v2 v2.0.0-20230315203717-e28e8ba9bc83
2023-04-26 15:22:10 +02:00
Sebastiaan van Stijn
1b263035af
Merge pull request #45374 from thaJeztah/23.0_backport_stfu_grpc
[23.0 backport] Silence GRPC logs unless our log level is debug
2023-04-26 15:21:47 +02:00
Sebastiaan van Stijn
682542fd08
Merge pull request #45373 from thaJeztah/23.0_backport_assorted_test_and_packaging
[23.0 backport] assorted test- and build/packaging fixes
2023-04-26 15:21:31 +02:00
Sebastiaan van Stijn
40ec0eb9fe
vendor: github.com/opencontainers/runc v1.1.5
no changes in vendored code, just keeping scanners happy :)

release notes: https://github.com/opencontainers/runc/releases/tag/v1.1.5
diff: https://github.com/opencontainers/runc/compare/v1.1.4...v1.1.5

This is the fifth patch release in the 1.1.z series of runc, which fixes
three CVEs found in runc.

* CVE-2023-25809 is a vulnerability involving rootless containers where
  (under specific configurations), the container would have write access
  to the /sys/fs/cgroup/user.slice/... cgroup hierarchy. No other
  hierarchies on the host were affected. This vulnerability was
  discovered by Akihiro Suda.
  <https://github.com/opencontainers/runc/security/advisories/GHSA-m8cg-xc2p-r3fc>

* CVE-2023-27561 was a regression which effectively re-introduced
  CVE-2019-19921. This bug was present from v1.0.0-rc95 to v1.1.4. This
  regression was discovered by @Beuc.
  <https://github.com/advisories/GHSA-vpvm-3wq2-2wvm>

* CVE-2023-28642 is a variant of CVE-2023-27561 and was fixed by the same
  patch. This variant of the above vulnerability was reported by Lei
  Wang.
  <https://github.com/opencontainers/runc/security/advisories/GHSA-g2j6-57v7-gm8c>

In addition, the following other fixes are included in this release:

* Fix the inability to use `/dev/null` when inside a container.
* Fix changing the ownership of host's `/dev/null` caused by fd redirection
  (a regression in 1.1.1).
* Fix rare runc exec/enter unshare error on older kernels, including
  CentOS < 7.7.
* nsexec: Check for errors in `write_log()`.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit a17029ba49)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-26 14:50:34 +02:00
Sebastiaan van Stijn
9af6762d34
Merge pull request #45403 from akerouanton/23.0-cherrypick-2d31697
[23.0 backport] daemon: set docker0 subpool as the IPAM pool
2023-04-26 14:34:41 +02:00
Sebastiaan van Stijn
0b6449a477
Merge pull request #45376 from thaJeztah/23.0_backport_delete_network_more_atomically
[23.0 backport] libnetwork: clean up inDelete network atomically
2023-04-26 13:11:30 +02:00
Albin Kerouanton
227d3f39a3
daemon: set docker0 subpool as the IPAM pool
Since cc19eba (backported to v23.0.4), the PreferredPool for docker0 is
set only when the user provides the bip config parameter or when the
default bridge already exist. That means, if a user provides the
fixed-cidr parameter on a fresh install or reboot their computer/server
without bip set, dockerd throw the following error when it starts:

> failed to start daemon: Error initializing network controller: Error
> creating default "bridge" network: failed to parse pool request for
> address space "LocalDefault" pool "" subpool "100.64.0.0/26": Invalid
> Address SubPool

See #45356.

Signed-off-by: Albin Kerouanton <albinker@gmail.com>
(cherry picked from commit 2d31697)
Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2023-04-26 11:38:55 +02:00
Sebastiaan van Stijn
6f83b8c3f4
Merge pull request #45372 from thaJeztah/23.0_backport_really_deprecate_newclient
[23.0 backport] client: deprecate NewClient properly
2023-04-25 18:31:47 +02:00
Cory Snider
c82be35412
libnetwork: clean up inDelete network atomically
The (*network).ipamRelease function nils out the network's IPAM info
fields, putting the network struct into an inconsistent state. The
network-restore startup code panics if it tries to restore a network
from a struct which has fewer IPAM config entries than IPAM info
entries. Therefore (*network).delete contains a critical section: by
persisting the network to the store after ipamRelease(), the datastore
will contain an inconsistent network until the deletion operation
completes and finishes deleting the network from the datastore. If for
any reason the deletion operation is interrupted between ipamRelease()
and deleteFromStore(), the daemon will crash on startup when it tries to
restore the network.

Updating the datastore after releasing the network's IPAM pools may have
served a purpose in the past, when a global datastore was used for
intra-cluster communication and the IPAM allocator had persistent global
state, but nowadays there is no global datastore and the IPAM allocator
has no persistent state whatsoever. Remove the vestigial datastore
update as it is no longer necessary and only serves to cause problems.
If the network deletion is interrupted before the network is deleted
from the datastore, the deletion will resume during the next daemon
startup, including releasing the IPAM pools.

Signed-off-by: Cory Snider <csnider@mirantis.com>
(cherry picked from commit c957ad0067)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-21 12:47:01 +02:00
Sebastiaan van Stijn
ccccb7a170
vendor: github.com/moby/swarmkit/v2 v2.0.0-20230315203717-e28e8ba9bc83
- CSI: Manager PublishVolume verify CSI node ID is not empty

full diff: a745a8755c...e28e8ba9bc

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 72dc7a0f7b)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-21 12:42:24 +02:00
Brian Goff
8a6bec6e16
Silence GRPC logs unless our log level is debug
GRPC is logging a *lot* of garbage at info level.
This configures the GRPC logger such that it is only giving us logs when
at debug level and also adds a log field indicating where the logs are
coming from.

containerd is still currently spewing these same log messages and needs
a separate update.

Without this change `docker build` is extremely noisy in the daemon
logs.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
(cherry picked from commit c7ccc68b15)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-21 12:33:33 +02:00
Aneesh Kulkarni
844fd50c67
Added timeout to validate job in github actions
Signed-off-by: Aneesh Kulkarni <askthefactorcamera@gmail.com>
(cherry picked from commit e5dbd28afd)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-21 12:29:21 +02:00