opencontainers / runc

CLI tool for spawning and running containers according to the OCI specification
https://www.opencontainers.org/
Apache License 2.0
11.78k stars 2.1k forks source link

Stop blacklisting Go 1.22+, drop Go < 1.21 support, use Go 1.22 in CI #4292

Closed kolyshkin closed 3 months ago

kolyshkin commented 4 months ago

High level overview:

See individual commits for details.

kolyshkin commented 4 months ago

We'll probably need to port the first 3 patches to release-1.1 (so that it will work with Go 1.22).

kolyshkin commented 4 months ago

btw, it seems the ubuntu builds are stalled.

This PR drops go 1.20.x tests, but they are marked as required in repo config -- this is why they are shown as "Expected -- waiting ...". I will fix the repo config accordingly (rm go 1.20.x, require go 1.22.x) once this PR will be ready to be merged (I guess once Go 1.21.4 is out).

kolyshkin commented 4 months ago

@opencontainers/runc-maintainers wdyt?

kolyshkin commented 4 months ago

@lifubang @cyphar PTAL

AkihiroSuda commented 4 months ago

CentOS tests seem failing

thaJeztah commented 4 months ago

CentOS tests seem failing

For CentOS stream 8, that may be expected; it's EOL since May 31 (just got hit by that in some CI pipeline that als had it in the Matrix)

AkihiroSuda commented 4 months ago

CentOS tests seem failing

For CentOS stream 8, that may be expected; it's EOL since May 31 (just got hit by that in some CI pipeline that als had it in the Matrix)

I guess we now have to replace CentOS with Alma, Rocky, or Oracle Linux?

lifubang commented 3 months ago

This one should be merged after go 1.22.4 has released.

kolyshkin commented 3 months ago

This one should be merged after go 1.22.4 has released.

Right, let's wait for it (added DNM).

kolyshkin commented 3 months ago

Go 1.22.4 is out, this PR is rebased with the following change:

diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 4c40b47b..7155c163 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -30,11 +30,6 @@ jobs:
         criu: ["", "criu-dev"]
         dmz: ["", "runc_nodmz"]
         exclude:
-          # Go 1.22 + glibc < 2.32 + nsenter does not play well (issue 4233),
-          # thus nsenter package won't compile. Disable ubuntu 20.04 + go 1.22.
-          # TODO: remove this once Go 1.22.4 is out.
-          - os: ubuntu-20.04
-            go-version: 1.22.x
           # Disable most of criu-dev jobs, as they are expensive
           # (need to compile criu) and don't add much value/coverage.
           - criu: criu-dev
kolyshkin commented 3 months ago

Ah, actions/setup-go still installs go 1.22.3 (given go 1.22.x). They always lag behind (see https://github.com/actions/setup-go/issues/407).

Have to wait a few days I guess (or specify the version number explicitly, which I don't want to).

Update: hmm, https://github.com/actions/go-versions/pull/100 is already merged, guess it needs to be propagated somehow (or the old cache invalidated, or smth).

kolyshkin commented 3 months ago

@lifubang PTAL (except for pinning go in ci to 1.22.4 this is all good, and we can revert this patch later)

AkihiroSuda commented 3 months ago

Needs rebase

kolyshkin commented 3 months ago

Assuming that by the time 1.2.0 is out, everyone will use Go 1.22.x >= 1.22.4, I just dropped the restriction (and added a note to README).

I think this is ready to be merged. WDYT @cyphar?