Bump docker packages
v2 cover Bump docker packages
Hi,
this series consists mostly of cherry-picks taken from home-assistant:
https://github.com/home-assistant/buildroot/commits/docker-29.8.1/
It was rebased and updated to the most recent versions.
Gitlab pipelines including runtime tests passed:
https://gitlab.com/bkuhls/buildroot/-/commits/b508633167765f5930848486d044551cfe3375b9
Regards, Bernd
v2: squashed version bumps (Julien)
Bernd Kuhls (1):
package/runc: bump version to 1.5.2
Jan Čermák (2):
package/docker-cli: bump version to v29.9.2
package/docker-engine: bump version to v29.9.2
Stefan Agner (3):
package/docker-engine: Fix go module version information package/docker-cli: Fix go module version information package/containerd: bump version to v2.3.7
package/containerd/containerd.hash | 2 +- package/containerd/containerd.mk | 2 +- package/docker-cli/docker-cli.hash | 2 +- package/docker-cli/docker-cli.mk | 12 +- package/docker-engine/Config.in | 1 + package/docker-engine/docker-engine.hash | 2 +- package/docker-engine/docker-engine.mk | 17 +- ...ror-checking-functions-with-their-er.patch | 375 ------------------ package/runc/runc.hash | 2 +- package/runc/runc.mk | 2 +- 10 files changed, 13 insertions(+), 404 deletions(-) delete mode 100644 package/runc/0001-Replace-os.Is-error-checking-functions-with-their-er.patch
Signature · 6 lines
2.47.3 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v2 1/6 package/docker-engine: Fix go module version information
From: Stefan Agner <[email protected]>
When using Docker engine built by Buildroot, the BuildKit version information appears as "v0.0.0+unknown" instead of the actual version (e.g., "v0.22.0").
This occurs because Buildroot's build process doesn't preserve Go module version information that Docker reads at runtime via debug.ReadBuildInfo() (see builder/builder-next/worker/worker.go).
Docker's own build system (hack/make/.binary) uses "-mod=vendor -modfile=vendor.mod" flags, which are crucial for preserving module dependency information. Adding these flags makes the previous vendoring workaround obsolete for modern Docker versions.
Note: Use "docker buildx ls" to verify the BuildKit version. This requires a Docker client with the buildx plugin installed.
Patch downloaded from
https://github.com/home-assistant/buildroot/commit/eb49dd0b3e7cbf00ec3849349251b9798a7d7f43
--- package/docker-engine/docker-engine.mk | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-)
package/docker-engine/docker-engine.mk +1 -9
@@ -25,6 +25,7 @@ DOCKER_ENGINE_LDFLAGS = \ DOCKER_ENGINE_TAGS = cgo exclude_graphdriver_zfs DOCKER_ENGINE_BUILD_TARGETS = cmd/dockerd cmd/docker-proxy +DOCKER_ENGINE_BUILD_OPTS += -mod=vendor -modfile=vendor.mod ifeq ($(BR2_PACKAGE_LIBAPPARMOR),y) DOCKER_ENGINE_DEPENDENCIES += libapparmor
@@ -61,15 +62,6 @@ else DOCKER_ENGINE_TAGS += exclude_graphdriver_vfs endif -# create the go.mod file with language version go1.19 -# remove the conflicting vendor/modules.txt -# https://github.com/moby/moby/issues/44618#issuecomment-1343565705 -define DOCKER_ENGINE_FIX_VENDORING - printf "module $(DOCKER_ENGINE_GOMOD)\n\ngo 1.19\n" > $(@D)/go.mod - rm -f $(@D)/vendor/modules.txt -endef -DOCKER_ENGINE_POST_EXTRACT_HOOKS += DOCKER_ENGINE_FIX_VENDORING - define DOCKER_ENGINE_INSTALL_INIT_SYSTEMD $(INSTALL) -D -m 0644 $(@D)/contrib/init/systemd/docker.service \ $(TARGET_DIR)/usr/lib/systemd/system/docker.service
Signature · 6 lines
2.47.3 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v2 1/6] package/docker-engine: Fix go module version information
Quoted 18 lines · Bernd Kuhls
From: Stefan Agner <[email protected]>
When using Docker engine built by Buildroot, the BuildKit version information appears as "v0.0.0+unknown" instead of the actual version (e.g., "v0.22.0").
This occurs because Buildroot's build process doesn't preserve Go module version information that Docker reads at runtime via
debug.ReadBuildInfo()(see builder/builder-next/worker/worker.go).Docker's own build system (hack/make/.binary) uses "-mod=vendor -modfile=vendor.mod" flags, which are crucial for preserving module dependency information. Adding these flags makes the previous vendoring workaround obsolete for modern Docker versions.
Note: Use "docker buildx ls" to verify the BuildKit version. This requires a Docker client with the buildx plugin installed.
Quoted 6 lines
Patch downloaded from
https://github.com/home-assistant/buildroot/commit/eb49dd0b3e7cbf00ec3849349251b9798a7d7f43Signed-off-by Stefan Agner <[email protected]>[Bernd: rebased]Signed-off-by Bernd Kuhls <[email protected]>
Series applied to master, thanks.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Raphaël Mélotte via buildroot
AppliedRe: [Buildroot] [PATCH v2 1/6] package/docker-engine: Fix go module version information
In reply to Bernd KuhlsIn reply of:
Quoted 16 lines
When using Docker engine built by Buildroot, the BuildKit version information appears as "v0.0.0+unknown" instead of the actual version (e.g., "v0.22.0").
This occurs because Buildroot's build process doesn't preserve Go module version information that Docker reads at runtime via
debug.ReadBuildInfo()(see builder/builder-next/worker/worker.go).Docker's own build system (hack/make/.binary) uses "-mod=vendor -modfile=vendor.mod" flags, which are crucial for preserving module dependency information. Adding these flags makes the previous vendoring workaround obsolete for modern Docker versions.
Note: Use "docker buildx ls" to verify the BuildKit version. This requires a Docker client with the buildx plugin installed.
Quoted 6 lines
Patch downloaded from
https://github.com/home-assistant/buildroot/commit/eb49dd0b3e7cbf00ec3849349251b9798a7d7f43Signed-off-by Stefan Agner <[email protected]>[Bernd: rebased]Signed-off-by Bernd Kuhls <[email protected]>
Applied to 2025.02.x, 2026.08.x. Thanks
Quoted 22 lines
--- package/docker-engine/docker-engine.mk | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-)package/docker-engine/docker-engine.mk +1
-2@@ -25,6 +25,7 @@ DOCKER_ENGINE_LDFLAGS = \ DOCKER_ENGINE_TAGS = cgo exclude_graphdriver_zfs DOCKER_ENGINE_BUILD_TARGETS = cmd/dockerd cmd/docker-proxy +DOCKER_ENGINE_BUILD_OPTS += -mod=vendor -modfile=vendor.mod ifeq ($(BR2_PACKAGE_LIBAPPARMOR),y) DOCKER_ENGINE_DEPENDENCIES += libapparmor@@ -61,15 +62,6 @@ else DOCKER_ENGINE_TAGS += exclude_graphdriver_vfs endif -# create the go.mod file with language version go1.19 -# remove the conflicting vendor/modules.txt
package/docker-engine/docker-engine.mk else · line 67
Quoted 10 lines
package/docker-engine/docker-engine.mk +0
-7-# https://github.com/moby/moby/issues/44618#issuecomment-1343565705 -define DOCKER_ENGINE_FIX_VENDORING - printf "module $(DOCKER_ENGINE_GOMOD)\n\ngo 1.19\n" > $(@D)/go.mod - rm -f $(@D)/vendor/modules.txt -endef -DOCKER_ENGINE_POST_EXTRACT_HOOKS += DOCKER_ENGINE_FIX_VENDORING - define DOCKER_ENGINE_INSTALL_INIT_SYSTEMD $(INSTALL) -D -m 0644 $(@D)/contrib/init/systemd/docker.service \ $(TARGET_DIR)/usr/lib/systemd/system/docker.service
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v2 2/6 package/docker-cli: Fix go module version information
In reply to Bernd KuhlsFrom: Stefan Agner <[email protected]>
Apply the same change from docker-engine to the docker-cli.
Docker's own build system (hack/make/.binary) uses "-mod=vendor -modfile=vendor.mod" flags, which are crucial for preserving module dependency information. Adding these flags makes the previous vendoring workaround obsolete for modern Docker versions.
Patch downloaded from
https://github.com/home-assistant/buildroot/commit/dba1173fb4cfb39624621f328fd2811f50a34513
--- package/docker-cli/docker-cli.mk | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-)
package/docker-cli/docker-cli.mk +1 -9
@@ -17,6 +17,7 @@ DOCKER_CLI_CPE_ID_PRODUCT = docker DOCKER_CLI_TAGS = autogen DOCKER_CLI_BUILD_TARGETS = cmd/docker +DOCKER_CLI_BUILD_OPTS += -mod=vendor -modfile=vendor.mod DOCKER_CLI_GOMOD = github.com/docker/cli DOCKER_CLI_LDFLAGS = \
@@ -29,13 +30,4 @@ DOCKER_CLI_TAGS += osusergo netgo DOCKER_CLI_GO_ENV = CGO_ENABLED=no endif -# create the go.mod file with language version go1.19 -# remove the conflicting vendor/modules.txt -# https://github.com/moby/moby/issues/44618#issuecomment-1343565705 -define DOCKER_CLI_FIX_VENDORING - printf "module $(DOCKER_CLI_GOMOD)\n\ngo 1.19\n" > $(@D)/go.mod - rm -f $(@D)/vendor/modules.txt -endef -DOCKER_CLI_POST_EXTRACT_HOOKS += DOCKER_CLI_FIX_VENDORING - $(eval $(golang-package))
Signature · 6 lines
2.47.3 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Raphaël Mélotte via buildroot
AppliedRe: [Buildroot] [PATCH v2 2/6] package/docker-cli: Fix go module version information
In reply of:
Quoted 7 lines
Apply the same change from docker-engine to the docker-cli.
Docker's own build system (hack/make/.binary) uses "-mod=vendor -modfile=vendor.mod" flags, which are crucial for preserving module dependency information. Adding these flags makes the previous vendoring workaround obsolete for modern Docker versions.
Quoted 5 lines
Patch downloaded from
https://github.com/home-assistant/buildroot/commit/dba1173fb4cfb39624621f328fd2811f50a34513Signed-off-by Stefan Agner <[email protected]>Signed-off-by Bernd Kuhls <[email protected]>
Applied to 2025.02.x, 2026.08.x. Thanks
Quoted 20 lines
--- package/docker-cli/docker-cli.mk | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-)package/docker-cli/docker-cli.mk +1
-0@@ -17,6 +17,7 @@ DOCKER_CLI_CPE_ID_PRODUCT = docker DOCKER_CLI_TAGS = autogen DOCKER_CLI_BUILD_TARGETS = cmd/docker +DOCKER_CLI_BUILD_OPTS += -mod=vendor -modfile=vendor.mod DOCKER_CLI_GOMOD = github.com/docker/cli DOCKER_CLI_LDFLAGS = \@@ -29,13 +30,4 @@ DOCKER_CLI_TAGS += osusergo netgo DOCKER_CLI_GO_ENV = CGO_ENABLED=no endif
package/docker-cli/docker-cli.mk DOCKER_CLI_TAGS += osusergo netgo · line 33
Quoted 10 lines
package/docker-cli/docker-cli.mk +0
-9-# create the go.mod file with language version go1.19 -# remove the conflicting vendor/modules.txt -# https://github.com/moby/moby/issues/44618#issuecomment-1343565705 -define DOCKER_CLI_FIX_VENDORING - printf "module $(DOCKER_CLI_GOMOD)\n\ngo 1.19\n" > $(@D)/go.mod - rm -f $(@D)/vendor/modules.txt -endef -DOCKER_CLI_POST_EXTRACT_HOOKS += DOCKER_CLI_FIX_VENDORING - $(eval $(golang-package))
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v2 3/6 package/containerd: bump version to v2.3.7
In reply to Bernd KuhlsFrom: Stefan Agner <[email protected]>
https://github.com/containerd/containerd/releases/tag/v2.1.3
https://github.com/containerd/containerd/releases/tag/v2.1.4
https://github.com/containerd/containerd/releases/tag/v2.1.5
https://github.com/containerd/containerd/releases/tag/v2.2.0
https://github.com/containerd/containerd/releases/tag/v2.2.1
https://github.com/containerd/containerd/releases/tag/v2.2.2
https://github.com/containerd/containerd/releases/tag/v2.2.4
https://github.com/containerd/containerd/releases/tag/v2.2.5
https://github.com/containerd/containerd/releases/tag/v2.2.6
https://github.com/containerd/containerd/releases/tag/v2.3.0
https://github.com/containerd/containerd/releases/tag/v2.3.1
https://github.com/containerd/containerd/releases/tag/v2.3.2
https://github.com/containerd/containerd/releases/tag/v2.3.3
https://github.com/containerd/containerd/releases/tag/v2.3.4
https://github.com/containerd/containerd/releases/tag/v2.3.5
https://github.com/containerd/containerd/releases/tag/v2.3.6
https://github.com/containerd/containerd/releases/tag/v2.3.7
[Bernd: squashed and rebased commits from
https://github.com/home-assistant/buildroot/commits/docker-29.8.1/]
--- package/containerd/containerd.hash | 2 +- package/containerd/containerd.mk | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
package/containerd/containerd.hash +1 -1
@@ -1,3 +1,3 @@ # Computed locally -sha256 a07e4bc9959ffdc409d2df22bd199be93fcb7a88f77b3c3dd1c07c199c01b42b containerd-2.0.14-go2.tar.gz +sha256 5d973b7d239de0e4cb72f6d4bad348a1540a80f394beb03f84a868714b06706c containerd-2.3.7-go2.tar.gz sha256 4bbe3b885e8cd1907ab4cf9a41e862e74e24b5422297a4f2fe524e6a30ada2b4 LICENSE
package/containerd/containerd.mk +1 -1
@@ -4,7 +4,7 @@ # ################################################################################ -CONTAINERD_VERSION = 2.0.14 +CONTAINERD_VERSION = 2.3.7 CONTAINERD_SITE = $(call github,containerd,containerd,v$(CONTAINERD_VERSION)) CONTAINERD_LICENSE = Apache-2.0 CONTAINERD_LICENSE_FILES = LICENSE
Signature · 6 lines
2.47.3 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v2 4/6 package/docker-cli: bump version to v29.9.2
In reply to Bernd KuhlsFrom: Jan Čermák <[email protected]>
https://docs.docker.com/engine/release-notes/29/#2912
https://docs.docker.com/engine/release-notes/29/#2913
https://docs.docker.com/engine/release-notes/29/#2921
https://docs.docker.com/engine/release-notes/29/#2931
https://docs.docker.com/engine/release-notes/29/#2952
https://docs.docker.com/engine/release-notes/29/#2953
https://docs.docker.com/engine/release-notes/29/#2962
https://docs.docker.com/engine/release-notes/29/#2972
https://docs.docker.com/engine/release-notes/29/#2980
https://docs.docker.com/engine/release-notes/29/#2981
https://docs.docker.com/engine/release-notes/29/#2982
https://docs.docker.com/engine/release-notes/29/#2990
https://docs.docker.com/engine/release-notes/29/#2991
https://docs.docker.com/engine/release-notes/29/#2992
[Bernd: squashed and rebased commits from
https://github.com/home-assistant/buildroot/commits/docker-29.8.1/
bump version to 29.9.2]
--- package/docker-cli/docker-cli.hash | 2 +- package/docker-cli/docker-cli.mk | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
package/docker-cli/docker-cli.hash +1 -1
@@ -1,3 +1,3 @@ # Locally calculated -sha256 5864ccdfceef3a9e8ddb29b4a555d5b82a551b5258067aac164b6156c6cfdc08 docker-cli-28.5.2-go2.tar.gz +sha256 e3b1fab5e2ee2d6b63b8ce0e8bbd08d6f54c0537c470332f2c345ab997233409 docker-cli-29.9.2-go2.tar.gz sha256 2d81ea060825006fc8f3fe28aa5dc0ffeb80faf325b612c955229157b8c10dc0 LICENSE
package/docker-cli/docker-cli.mk +1 -1
@@ -4,7 +4,7 @@ # ################################################################################ -DOCKER_CLI_VERSION = 28.5.2 +DOCKER_CLI_VERSION = 29.9.2 DOCKER_CLI_SITE = $(call github,docker,cli,v$(DOCKER_CLI_VERSION)) DOCKER_CLI_LICENSE = Apache-2.0
Signature · 6 lines
2.47.3 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v2 5/6 package/docker-engine: bump version to v29.9.2
In reply to Bernd KuhlsFrom: Jan Čermák <[email protected]>
Update to the latest version, adjust to the packaging and tagging changes and add nftables as a new dependency.
https://docs.docker.com/engine/release-notes/29/#2912
https://docs.docker.com/engine/release-notes/29/#2913
https://docs.docker.com/engine/release-notes/29/#2921
https://docs.docker.com/engine/release-notes/29/#2931
https://docs.docker.com/engine/release-notes/29/#2952
https://docs.docker.com/engine/release-notes/29/#2953
https://docs.docker.com/engine/release-notes/29/#2962
https://docs.docker.com/engine/release-notes/29/#2972
https://docs.docker.com/engine/release-notes/29/#2980
https://docs.docker.com/engine/release-notes/29/#2981
https://docs.docker.com/engine/release-notes/29/#2982
https://docs.docker.com/engine/release-notes/29/#2990
https://docs.docker.com/engine/release-notes/29/#2991
https://docs.docker.com/engine/release-notes/29/#2992
[Bernd: squashed and rebased commits from
https://github.com/home-assistant/buildroot/commits/docker-29.8.1/
bump version to 29.9.2]
--- package/docker-engine/Config.in | 1 + package/docker-engine/docker-engine.hash | 2 +- package/docker-engine/docker-engine.mk | 9 ++++----- 3 files changed, 6 insertions(+), 6 deletions(-)
package/docker-engine/Config.in +1 -0
@@ -12,6 +12,7 @@ config BR2_PACKAGE_DOCKER_ENGINE select BR2_PACKAGE_HOST_GO select BR2_PACKAGE_IPTABLES # runtime dependency select BR2_PACKAGE_LIBSECCOMP + select BR2_PACKAGE_NFTABLES help Docker is a platform to build, ship, and run applications as lightweight containers.
package/docker-engine/docker-engine.hash +1 -1
@@ -1,3 +1,3 @@ # Locally calculated -sha256 0e450c03c536a1304ba8fd26ca4c4ff96fac62182fd042fec90ffdf4a0969d40 docker-engine-28.5.2-go2.tar.gz +sha256 d7ce182528eb4c182f3884a7a83b7652ffcbc59b21d3d302050564ff949a9689 docker-engine-29.9.2-go2.tar.gz sha256 7c87873291f289713ac5df48b1f2010eb6963752bbd6b530416ab99fc37914a8 LICENSE
package/docker-engine/docker-engine.mk +4 -5
@@ -4,14 +4,14 @@ # ################################################################################ -DOCKER_ENGINE_VERSION = 28.5.2 -DOCKER_ENGINE_SITE = $(call github,moby,moby,v$(DOCKER_ENGINE_VERSION)) +DOCKER_ENGINE_VERSION = 29.9.2 +DOCKER_ENGINE_SITE = $(call github,moby,moby,docker-v$(DOCKER_ENGINE_VERSION)) DOCKER_ENGINE_LICENSE = Apache-2.0 DOCKER_ENGINE_LICENSE_FILES = LICENSE -DOCKER_ENGINE_DEPENDENCIES = host-pkgconf libseccomp -DOCKER_ENGINE_GOMOD = github.com/docker/docker +DOCKER_ENGINE_DEPENDENCIES = host-pkgconf libseccomp nftables +DOCKER_ENGINE_GOMOD = github.com/moby/moby/v2 DOCKER_ENGINE_CPE_ID_VENDOR = mobyproject DOCKER_ENGINE_CPE_ID_PRODUCT = moby
@@ -25,7 +25,6 @@ DOCKER_ENGINE_LDFLAGS = \ DOCKER_ENGINE_TAGS = cgo exclude_graphdriver_zfs DOCKER_ENGINE_BUILD_TARGETS = cmd/dockerd cmd/docker-proxy -DOCKER_ENGINE_BUILD_OPTS += -mod=vendor -modfile=vendor.mod ifeq ($(BR2_PACKAGE_LIBAPPARMOR),y) DOCKER_ENGINE_DEPENDENCIES += libapparmor
Signature · 6 lines
2.47.3 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v2 6/6 package/runc: bump version to 1.5.2
In reply to Bernd Kuhlshttps://github.com/opencontainers/runc/releases/tag/v1.4.0
https://github.com/opencontainers/runc/releases/tag/v1.4.1
https://github.com/opencontainers/runc/releases/tag/v1.4.2
https://github.com/opencontainers/runc/releases/tag/v1.4.3
https://github.com/opencontainers/runc/releases/tag/v1.5.0
"The runc 1.3.z release branch will now only receive high severity CVE fixes, and will no longer be supported in less than 6 months (end of October 2026)."
https://github.com/opencontainers/runc/releases/tag/v1.5.1
https://github.com/opencontainers/runc/releases/tag/v1.5.2
Removed patch which is included in this release.
--- ...ror-checking-functions-with-their-er.patch | 375 ------------------ package/runc/runc.hash | 2 +- package/runc/runc.mk | 2 +- 3 files changed, 2 insertions(+), 377 deletions(-) delete mode 100644 package/runc/0001-Replace-os.Is-error-checking-functions-with-their-er.patch
package/runc/0001-Replace-os.Is-error-checking-functions-with-their-er.patch deleted +0 -375
@@ -1,375 +0,0 @@ -From 87932aa3d01294886b71f9566f3bf881cf769c66 Mon Sep 17 00:00:00 2001 -From: Curd Becker <[email protected]> -Date: Mon, 17 Nov 2025 00:28:05 +0100 -Subject: [PATCH] Replace os.Is* error checking functions with their errors.Is - counterpart - -Signed-off-by: Curd Becker <[email protected]> -(cherry picked from commit 536e183451b7988316fdc37eecd7afd8570dc19b) -Signed-off-by: Kir Kolyshkin <[email protected]> -(cherry picked from commit 323a54ef0d91a20f7d5be4308e5e65a98886bf4b) - -Since the runc security bump to version 1.3.5 [1], the TestOci fail due -to missing user namespace support in the kernel: - - proc/self/setgroups: no such file or directory - -The test was working well with runc 1.3.0. The regression is caused by -this commit [2] from the 1.3.3 security release. - -The regression is fixed by a refactoring from the 1.4.1 release [3]. - -Backport this commit on top of runc 1.3.5 (fixing some conflicts). - -Upstream: https://github.com/opencontainers/runc/commit/323a54ef0d91a20f7d5be4308e5e65a98886bf4b - -[1] https://gitlab.com/buildroot.org/buildroot/-/commit/e013e2df84fb36985261d7b3c6e6af06afd40f93 -[2] https://github.com/opencontainers/runc/commit/7762edc82c36ba69a4ea88b86483fcdcac93f5a2 -[3] https://github.com/opencontainers/runc/commit/323a54ef0d91a20f7d5be4308e5e65a98886bf4b -[Romain: - rebase on 1.3.5 - add comments about runc 1.3.5 regression -] -Conflicts: - libcontainer/configs/validate/validator_test.go - libcontainer/container_linux.go - libcontainer/intelrdt/intelrdt.go -Signed-off-by: Romain Naour <[email protected]> -[Bernd: rebased for version 1.3.6] -Signed-off-by: Bernd Kuhls <[email protected]> ---- - libcontainer/configs/validate/validator.go | 6 +++--- - libcontainer/configs/validate/validator_test.go | 7 ++++--- - libcontainer/criu_linux.go | 10 +++++----- - libcontainer/devices/device_unix.go | 2 +- - libcontainer/factory_linux.go | 4 ++-- - libcontainer/init_linux.go | 4 ++-- - libcontainer/integration/exec_test.go | 6 +++--- - libcontainer/notify_linux.go | 2 +- - libcontainer/process_linux.go | 2 +- - libcontainer/rootfs_linux.go | 8 ++++---- - libcontainer/specconv/spec_linux_test.go | 5 +++-- - libcontainer/state_linux.go | 3 ++- - spec.go | 4 ++-- - 13 files changed, 33 insertions(+), 30 deletions(-) - -diff --git a/libcontainer/configs/validate/validator.go b/libcontainer/configs/validate/validator.go -index e0052900..3b77617b 100644 ---- a/libcontainer/configs/validate/validator.go -+++ b/libcontainer/configs/validate/validator.go -@@ -104,7 +104,7 @@ func security(config *configs.Config) error { - - func namespaces(config *configs.Config) error { - if config.Namespaces.Contains(configs.NEWUSER) { -- if _, err := os.Stat("/proc/self/ns/user"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/user"); errors.Is(err, os.ErrNotExist) { - return errors.New("user namespaces aren't enabled in the kernel") - } - hasPath := config.Namespaces.PathOf(configs.NEWUSER) != "" -@@ -122,13 +122,13 @@ func namespaces(config *configs.Config) error { - } - - if config.Namespaces.Contains(configs.NEWCGROUP) { -- if _, err := os.Stat("/proc/self/ns/cgroup"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/cgroup"); errors.Is(err, os.ErrNotExist) { - return errors.New("cgroup namespaces aren't enabled in the kernel") - } - } - - if config.Namespaces.Contains(configs.NEWTIME) { -- if _, err := os.Stat("/proc/self/timens_offsets"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/timens_offsets"); errors.Is(err, os.ErrNotExist) { - return errors.New("time namespaces aren't enabled in the kernel") - } - hasPath := config.Namespaces.PathOf(configs.NEWTIME) != "" -diff --git a/libcontainer/configs/validate/validator_test.go b/libcontainer/configs/validate/validator_test.go -index d157feea..41412ba4 100644 ---- a/libcontainer/configs/validate/validator_test.go -+++ b/libcontainer/configs/validate/validator_test.go -@@ -1,6 +1,7 @@ - package validate - - import ( -+ "errors" - "os" - "path/filepath" - "testing" -@@ -171,7 +172,7 @@ func TestValidateSecurityWithoutNEWNS(t *testing.T) { - } - - func TestValidateUserNamespace(t *testing.T) { -- if _, err := os.Stat("/proc/self/ns/user"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/user"); errors.Is(err, os.ErrNotExist) { - t.Skip("Test requires userns.") - } - config := &configs.Config{ -@@ -205,7 +206,7 @@ func TestValidateUsernsMappingWithoutNamespace(t *testing.T) { - } - - func TestValidateTimeNamespace(t *testing.T) { -- if _, err := os.Stat("/proc/self/ns/time"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/time"); errors.Is(err, os.ErrNotExist) { - t.Skip("Test requires timens.") - } - config := &configs.Config{ -@@ -224,7 +225,7 @@ func TestValidateTimeNamespace(t *testing.T) { - } - - func TestValidateTimeNamespaceWithBothPathAndTimeOffset(t *testing.T) { -- if _, err := os.Stat("/proc/self/ns/time"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/time"); errors.Is(err, os.ErrNotExist) { - t.Skip("Test requires timens.") - } - config := &configs.Config{ -diff --git a/libcontainer/criu_linux.go b/libcontainer/criu_linux.go -index 53a0202a..ddf95445 100644 ---- a/libcontainer/criu_linux.go -+++ b/libcontainer/criu_linux.go -@@ -123,7 +123,7 @@ func (c *Container) addMaskPaths(req *criurpc.CriuReq) error { - for _, path := range c.config.MaskPaths { - fi, err := os.Stat(fmt.Sprintf("/proc/%d/root/%s", c.initProcess.pid(), path)) - if err != nil { -- if os.IsNotExist(err) { -+ if errors.Is(err, os.ErrNotExist) { - continue - } - return err -@@ -304,7 +304,7 @@ func (c *Container) Checkpoint(criuOpts *CriuOpts) error { - - // Since a container can be C/R'ed multiple times, - // the checkpoint directory may already exist. -- if err := os.Mkdir(criuOpts.ImagesDirectory, 0o700); err != nil && !os.IsExist(err) { -+ if err := os.Mkdir(criuOpts.ImagesDirectory, 0o700); err != nil && !errors.Is(err, os.ErrExist) { - return err - } - -@@ -339,7 +339,7 @@ func (c *Container) Checkpoint(criuOpts *CriuOpts) error { - - // if criuOpts.WorkDirectory is not set, criu default is used. - if criuOpts.WorkDirectory != "" { -- if err := os.Mkdir(criuOpts.WorkDirectory, 0o700); err != nil && !os.IsExist(err) { -+ if err := os.Mkdir(criuOpts.WorkDirectory, 0o700); err != nil && !errors.Is(err, os.ErrExist) { - return err - } - workDir, err := os.Open(criuOpts.WorkDirectory) -@@ -698,7 +698,7 @@ func (c *Container) Restore(process *Process, criuOpts *CriuOpts) error { - if criuOpts.WorkDirectory != "" { - // Since a container can be C/R'ed multiple times, - // the work directory may already exist. -- if err := os.Mkdir(criuOpts.WorkDirectory, 0o700); err != nil && !os.IsExist(err) { -+ if err := os.Mkdir(criuOpts.WorkDirectory, 0o700); err != nil && !errors.Is(err, os.ErrExist) { - return err - } - workDir, err := os.Open(criuOpts.WorkDirectory) -@@ -1149,7 +1149,7 @@ func (c *Container) criuNotifications(resp *criurpc.CriuResp, process *Process, - return err - } - if err := os.Remove(filepath.Join(c.stateDir, "checkpoint")); err != nil { -- if !os.IsNotExist(err) { -+ if !errors.Is(err, os.ErrNotExist) { - logrus.Error(err) - } - } -diff --git a/libcontainer/devices/device_unix.go b/libcontainer/devices/device_unix.go -index c533eb1c..409e58e9 100644 ---- a/libcontainer/devices/device_unix.go -+++ b/libcontainer/devices/device_unix.go -@@ -98,7 +98,7 @@ func GetDevices(path string) ([]*Device, error) { - if errors.Is(err, ErrNotADevice) { - continue - } -- if os.IsNotExist(err) { -+ if errors.Is(err, os.ErrNotExist) { - continue - } - return nil, err -diff --git a/libcontainer/factory_linux.go b/libcontainer/factory_linux.go -index 94b55eaa..d8a2d8e3 100644 ---- a/libcontainer/factory_linux.go -+++ b/libcontainer/factory_linux.go -@@ -51,7 +51,7 @@ func Create(root, id string, config *configs.Config) (*Container, error) { - } - if _, err := os.Stat(stateDir); err == nil { - return nil, ErrExist -- } else if !os.IsNotExist(err) { -+ } else if !errors.Is(err, os.ErrNotExist) { - return nil, err - } - -@@ -154,7 +154,7 @@ func loadState(root string) (*State, error) { - } - f, err := os.Open(stateFilePath) - if err != nil { -- if os.IsNotExist(err) { -+ if errors.Is(err, os.ErrNotExist) { - return nil, ErrNotExist - } - return nil, err -diff --git a/libcontainer/init_linux.go b/libcontainer/init_linux.go -index 40529200..25c135f3 100644 ---- a/libcontainer/init_linux.go -+++ b/libcontainer/init_linux.go -@@ -311,7 +311,7 @@ func finalizeNamespace(config *initConfig) error { - switch { - case err == nil: - doChdir = false -- case os.IsPermission(err): -+ case errors.Is(err, os.ErrPermission): - // If we hit an EPERM, we should attempt again after setting up user. - // This will allow us to successfully chdir if the container user has access - // to the directory, but the user running runc does not. -@@ -477,7 +477,7 @@ func setupUser(config *initConfig) error { - setgroups, err = io.ReadAll(setgroupsFile) - _ = setgroupsFile.Close() - } -- if err != nil && !os.IsNotExist(err) { -+ if err != nil && !errors.Is(err, os.ErrNotExist) { - return err - } - -diff --git a/libcontainer/integration/exec_test.go b/libcontainer/integration/exec_test.go -index df99da26..14006922 100644 ---- a/libcontainer/integration/exec_test.go -+++ b/libcontainer/integration/exec_test.go -@@ -1097,7 +1097,7 @@ func TestHook(t *testing.T) { - - for _, hook := range []string{"prestart", "createRuntime", "poststart"} { - fi, err := os.Stat(filepath.Join(config.Rootfs, hook)) -- if err == nil || !os.IsNotExist(err) { -+ if err == nil || !errors.Is(err, os.ErrNotExist) { - t.Fatalf("expected file '%s to not exists, but it does", fi.Name()) - } - } -@@ -1645,7 +1645,7 @@ func TestTmpfsCopyUp(t *testing.T) { - } - - func TestCGROUPPrivate(t *testing.T) { -- if _, err := os.Stat("/proc/self/ns/cgroup"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/cgroup"); errors.Is(err, os.ErrNotExist) { - t.Skip("Test requires cgroupns.") - } - if testing.Short() { -@@ -1665,7 +1665,7 @@ func TestCGROUPPrivate(t *testing.T) { - } - - func TestCGROUPHost(t *testing.T) { -- if _, err := os.Stat("/proc/self/ns/cgroup"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/cgroup"); errors.Is(err, os.ErrNotExist) { - t.Skip("Test requires cgroupns.") - } - if testing.Short() { -diff --git a/libcontainer/notify_linux.go b/libcontainer/notify_linux.go -index a8762842..77e23157 100644 ---- a/libcontainer/notify_linux.go -+++ b/libcontainer/notify_linux.go -@@ -51,7 +51,7 @@ func registerMemoryEvent(cgDir string, evName string, arg string) (<-chan struct - } - // When a cgroup is destroyed, an event is sent to eventfd. - // So if the control path is gone, return instead of notifying. -- if _, err := os.Lstat(eventControlPath); os.IsNotExist(err) { -+ if _, err := os.Lstat(eventControlPath); errors.Is(err, os.ErrNotExist) { - return - } - ch <- struct{}{} -diff --git a/libcontainer/process_linux.go b/libcontainer/process_linux.go -index baf3706c..6f10a6c2 100644 ---- a/libcontainer/process_linux.go -+++ b/libcontainer/process_linux.go -@@ -940,7 +940,7 @@ func getPipeFds(pid int) ([]string, error) { - // Ignore permission errors, for rootless containers and other - // non-dumpable processes. if we can't get the fd for a particular - // file, there's not much we can do. -- if os.IsPermission(err) { -+ if errors.Is(err, os.ErrPermission) { - continue - } - return fds, err -diff --git a/libcontainer/rootfs_linux.go b/libcontainer/rootfs_linux.go -index 31d05174..abc372f3 100644 ---- a/libcontainer/rootfs_linux.go -+++ b/libcontainer/rootfs_linux.go -@@ -625,7 +625,7 @@ func mountToRootfs(c *mountConfig, m mountEntry) error { - return err - } - if fi, err := os.Lstat(dest); err != nil { -- if !os.IsNotExist(err) { -+ if !errors.Is(err, os.ErrNotExist) { - return err - } - } else if !fi.IsDir() { -diff --git a/libcontainer/specconv/spec_linux_test.go b/libcontainer/specconv/spec_linux_test.go -index 66359f79..88156516 100644 ---- a/libcontainer/specconv/spec_linux_test.go -+++ b/libcontainer/specconv/spec_linux_test.go -@@ -1,6 +1,7 @@ - package specconv - - import ( -+ "errors" - "os" - "strings" - "testing" -@@ -609,7 +610,7 @@ func TestDupNamespaces(t *testing.T) { - } - - func TestUserNamespaceMappingAndPath(t *testing.T) { -- if _, err := os.Stat("/proc/self/ns/user"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/user"); errors.Is(err, os.ErrNotExist) { - t.Skip("Test requires userns.") - } - -@@ -643,7 +644,7 @@ func TestUserNamespaceMappingAndPath(t *testing.T) { - } - - func TestNonZeroEUIDCompatibleSpecconvValidate(t *testing.T) { -- if _, err := os.Stat("/proc/self/ns/user"); os.IsNotExist(err) { -+ if _, err := os.Stat("/proc/self/ns/user"); errors.Is(err, os.ErrNotExist) { - t.Skip("Test requires userns.") - } - -diff --git a/libcontainer/state_linux.go b/libcontainer/state_linux.go -index 2b7b8b5b..1f758e2a 100644 ---- a/libcontainer/state_linux.go -+++ b/libcontainer/state_linux.go -@@ -1,6 +1,7 @@ - package libcontainer - - import ( -+ "errors" - "fmt" - "os" - "path/filepath" -@@ -213,7 +214,7 @@ func (r *restoredState) transition(s containerState) error { - - func (r *restoredState) destroy() error { - if _, err := os.Stat(filepath.Join(r.c.stateDir, "checkpoint")); err != nil { -- if !os.IsNotExist(err) { -+ if !errors.Is(err, os.ErrNotExist) { - return err - } - } -diff --git a/spec.go b/spec.go -index d03d644e..15e933eb 100644 ---- a/spec.go -+++ b/spec.go -@@ -91,7 +91,7 @@ created by an unprivileged user. - if err == nil { - return fmt.Errorf("File %s exists. Remove it first", name) - } -- if !os.IsNotExist(err) { -+ if !errors.Is(err, os.ErrNotExist) { - return err - } - return nil -@@ -117,7 +117,7 @@ created by an unprivileged user. - func loadSpec(cPath string) (spec *specs.Spec, err error) { - cf, err := os.Open(cPath) - if err != nil { -- if os.IsNotExist(err) { -+ if errors.Is(err, os.ErrNotExist) { - return nil, fmt.Errorf("JSON specification file %s not found", cPath) - } - return nil, err --- -2.54.0 -
package/runc/runc.hash +1 -1
@@ -1,3 +1,3 @@ # Locally computed -sha256 8816e8d4181d13012d16733e837425f5f67df57dfac28bc58a68f7dfcd54291b runc-1.3.6-go2.tar.gz +sha256 b5af44864a830c7032cf4a72efa0c6d44f701873d9507b127be31ad4d1d42ff3 runc-1.5.2-go2.tar.gz sha256 552a739c3b25792263f731542238b92f6f8d07e9a488eae27e6c4690038a8243 LICENSE
package/runc/runc.mk +1 -1
@@ -4,7 +4,7 @@ # ################################################################################ -RUNC_VERSION = 1.3.6 +RUNC_VERSION = 1.5.2 RUNC_SITE = $(call github,opencontainers,runc,v$(RUNC_VERSION)) RUNC_LICENSE = Apache-2.0, LGPL-2.1 (libseccomp) RUNC_LICENSE_FILES = LICENSE
Signature · 6 lines
2.47.3 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot