From 7e95bbab35271ac4069b85a885f263c5936527de Mon Sep 17 00:00:00 2001 From: CrazyMax <1951866+crazy-max@users.noreply.github.com> Date: Sat, 14 Jun 2025 20:58:19 +0200 Subject: [PATCH 1/3] rpm: add rockylinux 8 and 9 Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com> --- Makefile | 2 +- docker-bake.hcl | 28 +++++++++++++++++++++++++++- hack/scripts/rpm-init.sh | 8 ++++++++ hack/scripts/verify-rpm-init.sh | 8 ++++++++ 4 files changed, 44 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 2b39eb17..6bc09d82 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ # Same as ones in docker-bake.hcl DISTROS_DEB ?= debian11 debian12 debian13 ubuntu2204 ubuntu2404 raspbian11 raspbian12 -DISTROS_RPM ?= centos9 fedora41 fedora42 oraclelinux8 oraclelinux9 +DISTROS_RPM ?= centos9 fedora41 fedora42 oraclelinux8 oraclelinux9 rockylinux8 rockylinux9 DISTROS_STATIC ?= static DISTROS ?= $(DISTROS_DEB) $(DISTROS_RPM) $(DISTROS_STATIC) diff --git a/docker-bake.hcl b/docker-bake.hcl index bb33955a..cb714192 100644 --- a/docker-bake.hcl +++ b/docker-bake.hcl @@ -27,7 +27,9 @@ variable "DISTROS" { "fedora41", "fedora42", "oraclelinux8", - "oraclelinux9" + "oraclelinux9", + "rockylinux8", + "rockylinux9" ] } @@ -298,6 +300,28 @@ target "_distro-oraclelinux9" { } } +target "_distro-rockylinux8" { + args = { + DISTRO_NAME = "rockylinux8" + DISTRO_TYPE = "rpm" + DISTRO_RELEASE = "rockylinux" + DISTRO_ID = "8" + DISTRO_SUITE = "8" + DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "rockylinux/rockylinux:8" + } +} + +target "_distro-rockylinux9" { + args = { + DISTRO_NAME = "rockylinux9" + DISTRO_TYPE = "rpm" + DISTRO_RELEASE = "rockylinux" + DISTRO_ID = "9" + DISTRO_SUITE = "9" + DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "rockylinux/rockylinux:9" + } +} + # Returns the list of supported platforms for a given distro and package. # The result is the intersection of the platforms supported by the distro # and the platforms supported by the package. Except for static distro, @@ -321,6 +345,8 @@ function "distroPlatforms" { fedora42 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] oraclelinux8 = ["linux/amd64", "linux/arm64"] oraclelinux9 = ["linux/amd64", "linux/arm64"] + rockylinux8 = ["linux/amd64", "linux/arm64"] + rockylinux9 = ["linux/amd64", "linux/arm64"] }, distro, []), pkgPlatforms(pkg) ), diff --git a/hack/scripts/rpm-init.sh b/hack/scripts/rpm-init.sh index 3770fe65..4d0970fa 100755 --- a/hack/scripts/rpm-init.sh +++ b/hack/scripts/rpm-init.sh @@ -51,4 +51,12 @@ case "$pkgrelease" in fedora*) dnf install -y git rpm-build rpmlint dnf-plugins-core ;; + rockylinux8) + dnf install -y git rpm-build rpmlint dnf-plugins-core epel-release + dnf config-manager --set-enabled devel + ;; + rockylinux*) + dnf install -y git rpm-build rpmlint dnf-plugins-core epel-release + dnf config-manager --set-enabled crb + ;; esac diff --git a/hack/scripts/verify-rpm-init.sh b/hack/scripts/verify-rpm-init.sh index a865e825..1013f822 100755 --- a/hack/scripts/verify-rpm-init.sh +++ b/hack/scripts/verify-rpm-init.sh @@ -40,4 +40,12 @@ case "$pkgrelease" in fedora*) dnf install -y findutils dnf-plugins-core ;; + rockylinux8) + dnf install -y findutils dnf-plugins-core epel-release + dnf config-manager --set-enabled devel + ;; + rockylinux*) + dnf install -y findutils dnf-plugins-core epel-release + dnf config-manager --set-enabled crb + ;; esac From 104a608d49a9de69bd0ccad737cf737bd38015f6 Mon Sep 17 00:00:00 2001 From: CrazyMax <1951866+crazy-max@users.noreply.github.com> Date: Sat, 14 Jun 2025 21:01:17 +0200 Subject: [PATCH 2/3] rpm: add almalinux 8 and 9 Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com> --- Makefile | 2 +- docker-bake.hcl | 28 +++++++++++++++++++++++++++- hack/scripts/rpm-init.sh | 6 +++--- hack/scripts/verify-rpm-init.sh | 6 +++--- 4 files changed, 34 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index 6bc09d82..2ec8f65f 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ # Same as ones in docker-bake.hcl DISTROS_DEB ?= debian11 debian12 debian13 ubuntu2204 ubuntu2404 raspbian11 raspbian12 -DISTROS_RPM ?= centos9 fedora41 fedora42 oraclelinux8 oraclelinux9 rockylinux8 rockylinux9 +DISTROS_RPM ?= centos9 fedora41 fedora42 oraclelinux8 oraclelinux9 rockylinux8 rockylinux9 almalinux8 almalinux9 DISTROS_STATIC ?= static DISTROS ?= $(DISTROS_DEB) $(DISTROS_RPM) $(DISTROS_STATIC) diff --git a/docker-bake.hcl b/docker-bake.hcl index cb714192..9d98d48d 100644 --- a/docker-bake.hcl +++ b/docker-bake.hcl @@ -29,7 +29,9 @@ variable "DISTROS" { "oraclelinux8", "oraclelinux9", "rockylinux8", - "rockylinux9" + "rockylinux9", + "almalinux8", + "almalinux9" ] } @@ -322,6 +324,28 @@ target "_distro-rockylinux9" { } } +target "_distro-almalinux8" { + args = { + DISTRO_NAME = "almalinux8" + DISTRO_TYPE = "rpm" + DISTRO_RELEASE = "almalinux" + DISTRO_ID = "8" + DISTRO_SUITE = "8" + DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "almalinux:8" + } +} + +target "_distro-almalinux9" { + args = { + DISTRO_NAME = "almalinux9" + DISTRO_TYPE = "rpm" + DISTRO_RELEASE = "almalinux" + DISTRO_ID = "9" + DISTRO_SUITE = "9" + DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "almalinux:9" + } +} + # Returns the list of supported platforms for a given distro and package. # The result is the intersection of the platforms supported by the distro # and the platforms supported by the package. Except for static distro, @@ -347,6 +371,8 @@ function "distroPlatforms" { oraclelinux9 = ["linux/amd64", "linux/arm64"] rockylinux8 = ["linux/amd64", "linux/arm64"] rockylinux9 = ["linux/amd64", "linux/arm64"] + almalinux8 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] + almalinux9 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] }, distro, []), pkgPlatforms(pkg) ), diff --git a/hack/scripts/rpm-init.sh b/hack/scripts/rpm-init.sh index 4d0970fa..73e77161 100755 --- a/hack/scripts/rpm-init.sh +++ b/hack/scripts/rpm-init.sh @@ -51,11 +51,11 @@ case "$pkgrelease" in fedora*) dnf install -y git rpm-build rpmlint dnf-plugins-core ;; - rockylinux8) + rockylinux8|almalinux8) dnf install -y git rpm-build rpmlint dnf-plugins-core epel-release - dnf config-manager --set-enabled devel + dnf config-manager --set-enabled powertools ;; - rockylinux*) + rockylinux*|almalinux*) dnf install -y git rpm-build rpmlint dnf-plugins-core epel-release dnf config-manager --set-enabled crb ;; diff --git a/hack/scripts/verify-rpm-init.sh b/hack/scripts/verify-rpm-init.sh index 1013f822..f92ed2ef 100755 --- a/hack/scripts/verify-rpm-init.sh +++ b/hack/scripts/verify-rpm-init.sh @@ -40,11 +40,11 @@ case "$pkgrelease" in fedora*) dnf install -y findutils dnf-plugins-core ;; - rockylinux8) + rockylinux8|almalinux8) dnf install -y findutils dnf-plugins-core epel-release - dnf config-manager --set-enabled devel + dnf config-manager --set-enabled powertools ;; - rockylinux*) + rockylinux*|almalinux*) dnf install -y findutils dnf-plugins-core epel-release dnf config-manager --set-enabled crb ;; From 84d036acd163d19f7c14bd7db645bb7446191010 Mon Sep 17 00:00:00 2001 From: CrazyMax <1951866+crazy-max@users.noreply.github.com> Date: Fri, 27 Jun 2025 13:25:36 +0200 Subject: [PATCH 3/3] sort distros Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com> --- Makefile | 23 ++++++++++++++++---- docker-bake.hcl | 58 ++++++++++++++++++++++++++----------------------- 2 files changed, 50 insertions(+), 31 deletions(-) diff --git a/Makefile b/Makefile index 2ec8f65f..78a9a0b0 100644 --- a/Makefile +++ b/Makefile @@ -13,10 +13,25 @@ # limitations under the License. # Same as ones in docker-bake.hcl -DISTROS_DEB ?= debian11 debian12 debian13 ubuntu2204 ubuntu2404 raspbian11 raspbian12 -DISTROS_RPM ?= centos9 fedora41 fedora42 oraclelinux8 oraclelinux9 rockylinux8 rockylinux9 almalinux8 almalinux9 -DISTROS_STATIC ?= static -DISTROS ?= $(DISTROS_DEB) $(DISTROS_RPM) $(DISTROS_STATIC) +DISTROS ?= static \ + \ + debian11 \ + debian12 \ + debian13 \ + raspbian11 \ + raspbian12 \ + ubuntu2204 \ + ubuntu2404 \ + \ + almalinux8 \ + almalinux9 \ + centos9 \ + fedora41 \ + fedora42 \ + oraclelinux8 \ + oraclelinux9 \ + rockylinux8 \ + rockylinux9 # Should match ones from docker-bake.hcl PKGS_RAW := $(notdir $(shell find "pkg/" -maxdepth 1 -type d)) diff --git a/docker-bake.hcl b/docker-bake.hcl index 9d98d48d..7457598b 100644 --- a/docker-bake.hcl +++ b/docker-bake.hcl @@ -16,6 +16,7 @@ variable "DISTROS" { description = "List of supported distros. Don't forget to update _distro-* target if you add/remove a distro." default = [ "static", + "debian11", "debian12", "debian13", @@ -23,15 +24,16 @@ variable "DISTROS" { "raspbian12", "ubuntu2204", "ubuntu2404", + + "almalinux8", + "almalinux9", "centos9", "fedora41", "fedora42", "oraclelinux8", "oraclelinux9", "rockylinux8", - "rockylinux9", - "almalinux8", - "almalinux9" + "rockylinux9" ] } @@ -247,6 +249,28 @@ target "_distro-ubuntu2404" { } } +target "_distro-almalinux8" { + args = { + DISTRO_NAME = "almalinux8" + DISTRO_TYPE = "rpm" + DISTRO_RELEASE = "almalinux" + DISTRO_ID = "8" + DISTRO_SUITE = "8" + DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "almalinux:8" + } +} + +target "_distro-almalinux9" { + args = { + DISTRO_NAME = "almalinux9" + DISTRO_TYPE = "rpm" + DISTRO_RELEASE = "almalinux" + DISTRO_ID = "9" + DISTRO_SUITE = "9" + DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "almalinux:9" + } +} + target "_distro-centos9" { args = { DISTRO_NAME = "centos9" @@ -324,28 +348,6 @@ target "_distro-rockylinux9" { } } -target "_distro-almalinux8" { - args = { - DISTRO_NAME = "almalinux8" - DISTRO_TYPE = "rpm" - DISTRO_RELEASE = "almalinux" - DISTRO_ID = "8" - DISTRO_SUITE = "8" - DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "almalinux:8" - } -} - -target "_distro-almalinux9" { - args = { - DISTRO_NAME = "almalinux9" - DISTRO_TYPE = "rpm" - DISTRO_RELEASE = "almalinux" - DISTRO_ID = "9" - DISTRO_SUITE = "9" - DISTRO_IMAGE = DISTRO_IMAGE != null ? DISTRO_IMAGE : "almalinux:9" - } -} - # Returns the list of supported platforms for a given distro and package. # The result is the intersection of the platforms supported by the distro # and the platforms supported by the package. Except for static distro, @@ -357,6 +359,7 @@ function "distroPlatforms" { setintersection( lookup({ static = pkgPlatforms(pkg) + debian11 = ["linux/386", "linux/amd64", "linux/arm64", "linux/arm/v7", "linux/mips64le", "linux/ppc64le", "linux/s390x"] debian12 = ["linux/386", "linux/amd64", "linux/arm64", "linux/arm/v7", "linux/mips64le", "linux/ppc64le", "linux/s390x"] debian13 = ["linux/386", "linux/amd64", "linux/arm64", "linux/arm/v7", "linux/mips64le", "linux/ppc64le", "linux/riscv64", "linux/s390x"] @@ -364,6 +367,9 @@ function "distroPlatforms" { raspbian12 = ["linux/arm/v7"] ubuntu2204 = ["linux/amd64", "linux/arm64", "linux/arm/v7", "linux/ppc64le", "linux/s390x"] ubuntu2404 = ["linux/amd64", "linux/arm64", "linux/arm/v7", "linux/ppc64le", "linux/riscv64", "linux/s390x"] + + almalinux8 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] + almalinux9 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] centos9 = ["linux/amd64", "linux/arm64", "linux/ppc64le"] fedora41 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] fedora42 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] @@ -371,8 +377,6 @@ function "distroPlatforms" { oraclelinux9 = ["linux/amd64", "linux/arm64"] rockylinux8 = ["linux/amd64", "linux/arm64"] rockylinux9 = ["linux/amd64", "linux/arm64"] - almalinux8 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] - almalinux9 = ["linux/amd64", "linux/arm64", "linux/ppc64le", "linux/s390x"] }, distro, []), pkgPlatforms(pkg) ),