From 724b9f89557de4d6e70a9d68882afb1b27e5ac57 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Sat, 20 Jan 2024 23:32:56 +0100 Subject: [PATCH] downgrade minimum required version of hcsshim to v0.10.0 This updates the minimum required version for hcsshim's "osversion" package to v0.10.0, which is the first (non-rc) version providine the `CheckHostAndContainerCompat` utility that's used, which was added in [microsoft/hcsshim@640a560]. Containerd 1.6 LTS currently uses hcsshim [v0.9.10], so would need to be updated to use the platforms module. Containerd 1.7 already uses hcsshim [v0.11.4], so can continue using that version (or higher if needed). This patch downgrades the required version to the lowest version providing the `CheckHostAndContainerCompat`, to make Go modules "minimum version selection" work, and to allow consumers to select a version of the hcsshim needed for their use (any version higher than v0.10.0). [microsoft/hcsshim@640a560]: https://github.com/microsoft/hcsshim/commit/640a5606a855a275cda5b8862221ae32b09b6a35 [v0.9.10]: https://github.com/containerd/containerd/blob/v1.6.27/go.mod#L9 [v0.11.4]: https://github.com/containerd/containerd/blob/v1.7.12/go.mod#L10 Signed-off-by: Sebastiaan van Stijn --- go.mod | 4 ++-- go.sum | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/go.mod b/go.mod index aea1e57..81aa215 100644 --- a/go.mod +++ b/go.mod @@ -3,11 +3,11 @@ module github.com/containerd/platforms go 1.20 require ( - github.com/Microsoft/hcsshim v0.12.0-rc.2 + github.com/Microsoft/hcsshim v0.10.0 github.com/containerd/log v0.1.0 github.com/opencontainers/image-spec v1.1.0-rc5 github.com/stretchr/testify v1.8.4 - golang.org/x/sys v0.16.0 + golang.org/x/sys v0.10.0 ) require ( diff --git a/go.sum b/go.sum index fb58376..a28ca24 100644 --- a/go.sum +++ b/go.sum @@ -1,5 +1,5 @@ -github.com/Microsoft/hcsshim v0.12.0-rc.2 h1:gfKebjq3Mq17Ys+4cjE8vc2h6tZVeqCGb9a7vBVqpAk= -github.com/Microsoft/hcsshim v0.12.0-rc.2/go.mod h1:G2TZhBED5frlh/hsuxV5CDh/ylkSFknPAMPpQg9owQw= +github.com/Microsoft/hcsshim v0.10.0 h1:PbvoxdUGgXxyirmN5Oncp3POLkxEG5LbWCEBfWmHTGA= +github.com/Microsoft/hcsshim v0.10.0/go.mod h1:3j1trOamcUdi86J5Tr5+1BpqMjSv/QeRWkX2whBF6dY= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -18,8 +18,8 @@ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= -golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.10.0 h1:SqMFp9UcQJZa+pmYuAKjd9xq1f0j5rLcDIk0mj4qAsA= +golang.org/x/sys v0.10.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=