]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Ensure yum is installed for rpm Docker builds
authorNick Porter <nick@portercomputing.co.uk>
Fri, 10 May 2024 09:48:07 +0000 (10:48 +0100)
committerNick Porter <nick@portercomputing.co.uk>
Fri, 10 May 2024 11:29:23 +0000 (12:29 +0100)
scripts/docker/build/rocky9/Dockerfile
scripts/docker/build/rocky9/Dockerfile.cb
scripts/docker/m4/crossbuild.rpm.m4
scripts/docker/m4/docker.rpm.m4

index 372778c17799b6036690a5364ef9141441a956a8..039816beb87be4429a46bd261b8e1cd38df54cf5 100644 (file)
@@ -8,6 +8,11 @@ FROM ${from} as build
 
 RUN rpmkeys --import /etc/pki/rpm-gpg/RPM-GPG-KEY-Rocky-9
 
+#
+#  Ensure yum is installed.  Some docker images only have microdnf
+#
+RUN if [ ! -e /usr/bin/yum ]; then if [ -e /usr/bin/dnf ]; then dnf install -y yum; else microdnf install -y yum; fi; fi
+
 #
 #  Install build tools
 #
@@ -113,6 +118,8 @@ RUN rpm --import https://packages.networkradius.com/pgp/packages@networkradius.c
 #  Other requirements
 #
 
+RUN if [ ! -e /usr/bin/yum ]; then if [ -e /usr/bin/dnf ]; then dnf install -y yum; else microdnf install -y yum; fi; fi
+
 #  Needed for mysql-libs on Rocky 9
 RUN yum install -y yum-utils
 RUN yum config-manager --enable crb
index 1bb069cf268d65d46c88cb69f97e9d93dd6e0250..163e313891cdfa200aeb39ea29f591a4ffa1db5b 100644 (file)
@@ -6,6 +6,11 @@
 ARG from=rockylinux/rockylinux:9
 FROM ${from} as build
 
+#
+#  Ensure yum is installed.  Some docker images only have dnf or microdnf
+#
+RUN if [ ! -e /usr/bin/yum ]; then if [ -e /usr/bin/dnf ]; then dnf install -y yum; else microdnf install -y yum; fi; fi
+
 #
 #  Install devtools like make and git and the EPEL
 #  repository for freetds and hiredis
index 1c7465fb526ab156faf09d1683c633ce1ad5fd88..e2f966293bfe291981aa134d4a372a33449b4bd0 100644 (file)
@@ -1,6 +1,11 @@
 ARG from=DOCKER_IMAGE
 FROM ${from} as build
 
+#
+#  Ensure yum is installed.  Some docker images only have dnf or microdnf
+#
+RUN if [ ! -e /usr/bin/yum ]; then if [ -e /usr/bin/dnf ]; then dnf install -y yum; else microdnf install -y yum; fi; fi
+
 #
 #  Install devtools like make and git and the EPEL
 #  repository for freetds and hiredis
index d75f8216580910159d5cd59c7301cc593a3cde11..82a641d5270c78f778853f15d4f30ac9a8492146 100644 (file)
@@ -7,6 +7,12 @@ RUN rpmkeys --import /etc/pki/rpm-gpg/RPM-GPG-KEY-rockyofficial
 ifelse(OS_VER, 9, `dnl
 RUN rpmkeys --import /etc/pki/rpm-gpg/RPM-GPG-KEY-Rocky-9
 ')
+
+#
+#  Ensure yum is installed.  Some docker images only have dnf or microdnf
+#
+RUN if [ ! -e /usr/bin/yum ]; then if [ -e /usr/bin/dnf ]; then dnf install -y yum; else microdnf install -y yum; fi; fi
+
 #
 #  Install build tools
 #
@@ -149,6 +155,8 @@ gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-LTB-project'\
 })dnl
 changequote({`}, {'})dnl
 
+RUN if [ ! -e /usr/bin/yum ]; then if [ -e /usr/bin/dnf ]; then dnf install -y yum; else microdnf install -y yum; fi; fi
+
 ifelse(OS_VER, 9, `dnl
 #  Needed for mysql-libs on Rocky 9
 RUN yum install -y yum-utils