From c7d8334d2689eee5f7e6562defeb99b1836fac52 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Wed, 12 May 2021 14:19:58 +0200 Subject: [PATCH] ci: don't use `rpm` to determine the kernel version for `/etc/profile.d/dracut-test.sh` --- test/container/Dockerfile-Arch | 2 +- test/container/Dockerfile-Fedora-33 | 2 +- test/container/Dockerfile-Fedora-34 | 2 +- test/container/Dockerfile-Fedora-latest | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/container/Dockerfile-Arch b/test/container/Dockerfile-Arch index 9340e50f0..4dcb24dda 100644 --- a/test/container/Dockerfile-Arch +++ b/test/container/Dockerfile-Arch @@ -5,7 +5,7 @@ MAINTAINER https://github.com/dracutdevs/dracut ENV container docker LABEL RUN="docker run -it --name NAME --privileged --ipc=host --net=host --pid=host -e NAME=NAME -e IMAGE=IMAGE IMAGE" -RUN echo 'export DRACUT_NO_XATTR=1 KVERSION="$(rpm -qa kernel --qf "%{VERSION}-%{RELEASE}.%{ARCH}\n" | sort -rn | head -1)"' > /etc/profile.d/dracut-test.sh +RUN echo 'export DRACUT_NO_XATTR=1 KVERSION=$(cd /lib/modules; ls -1 | tail -1)' > /etc/profile.d/dracut-test.sh # Install needed packages for the dracut CI container RUN pacman --noconfirm -Sy \ diff --git a/test/container/Dockerfile-Fedora-33 b/test/container/Dockerfile-Fedora-33 index 37208d476..d0c943bd0 100644 --- a/test/container/Dockerfile-Fedora-33 +++ b/test/container/Dockerfile-Fedora-33 @@ -5,7 +5,7 @@ MAINTAINER https://github.com/dracutdevs/dracut ENV container docker LABEL RUN="docker run -it --name NAME --privileged --ipc=host --net=host --pid=host -e NAME=NAME -e IMAGE=IMAGE IMAGE" -RUN echo 'export DRACUT_NO_XATTR=1 KVERSION="$(rpm -qa kernel --qf "%{VERSION}-%{RELEASE}.%{ARCH}\n" | sort -rn | head -1)"' > /etc/profile.d/dracut-test.sh +RUN echo 'export DRACUT_NO_XATTR=1 KVERSION=$(cd /lib/modules; ls -1 | tail -1)' > /etc/profile.d/dracut-test.sh # Install needed packages for the dracut CI container RUN dnf -y install --setopt=install_weak_deps=False \ diff --git a/test/container/Dockerfile-Fedora-34 b/test/container/Dockerfile-Fedora-34 index 72cdae728..e40c1c906 100644 --- a/test/container/Dockerfile-Fedora-34 +++ b/test/container/Dockerfile-Fedora-34 @@ -5,7 +5,7 @@ MAINTAINER https://github.com/dracutdevs/dracut ENV container docker LABEL RUN="docker run -it --name NAME --privileged --ipc=host --net=host --pid=host -e NAME=NAME -e IMAGE=IMAGE IMAGE" -RUN echo 'export DRACUT_NO_XATTR=1 KVERSION="$(rpm -qa kernel --qf "%{VERSION}-%{RELEASE}.%{ARCH}\n" | sort -rn | head -1)"' > /etc/profile.d/dracut-test.sh +RUN echo 'export DRACUT_NO_XATTR=1 KVERSION=$(cd /lib/modules; ls -1 | tail -1)' > /etc/profile.d/dracut-test.sh # Install needed packages for the dracut CI container RUN dnf -y install --setopt=install_weak_deps=False \ diff --git a/test/container/Dockerfile-Fedora-latest b/test/container/Dockerfile-Fedora-latest index b6c1e2715..bfc5a98eb 100644 --- a/test/container/Dockerfile-Fedora-latest +++ b/test/container/Dockerfile-Fedora-latest @@ -5,7 +5,7 @@ MAINTAINER https://github.com/dracutdevs/dracut ENV container docker LABEL RUN="docker run -it --name NAME --privileged --ipc=host --net=host --pid=host -e NAME=NAME -e IMAGE=IMAGE IMAGE" -RUN echo 'export DRACUT_NO_XATTR=1 KVERSION="$(rpm -qa kernel --qf "%{VERSION}-%{RELEASE}.%{ARCH}\n" | sort -rn | head -1)"' > /etc/profile.d/dracut-test.sh +RUN echo 'export DRACUT_NO_XATTR=1 KVERSION=$(cd /lib/modules; ls -1 | tail -1)' > /etc/profile.d/dracut-test.sh # Install needed packages for the dracut CI container RUN dnf -y install --setopt=install_weak_deps=False \ -- 2.47.3