From f39564d84339750f21238982a1d718fcd2ad6d7e Mon Sep 17 00:00:00 2001 From: Dirk Date: Fri, 13 Oct 2023 17:07:38 +0200 Subject: [PATCH 1/2] Make sure util_Linux gets replaced as intended There were some discussions in #2420 whether the zypper install commend worked as intended. While there's liitle doubt that those packages weren't installed this PR makes really sure that this is the case. Also it does an update via ``zypper up`` as the image provided from dockerhub seemed to be somewhat behind. --- Dockerfile | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 8c5e589..f672bf1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,12 +6,20 @@ ARG INSTALL_ROOT=/rootfs FROM opensuse/leap:${LEAP_VERSION} as builder ARG CACHE_ZYPPER=/tmp/cache/zypper ARG INSTALL_ROOT -# /etc/os-release provides $VERSION_ID + + +# /etc/os-release provides $VERSION_ID below. +# We don't need the openh264.repo and the non-oss repos, just costs build time (repo caches). +# Also we need to remove the util_linux RPM to /really/ make sure busybox-util-linux gets installed. +# And we need to update, see PR #2424 RUN source /etc/os-release \ + && rm -f /etc/zypp/repos.d/repo-openh264.repo /etc/zypp/repos.d/repo-non-oss.repo \ && export ZYPPER_OPTIONS=( --releasever "${VERSION_ID}" --installroot "${INSTALL_ROOT}" --cache-dir "${CACHE_ZYPPER}" ) \ && zypper "${ZYPPER_OPTIONS[@]}" --gpg-auto-import-keys refresh \ + && rpm -e util-linux --nodeps \ && zypper "${ZYPPER_OPTIONS[@]}" --non-interactive install --download-in-advance --no-recommends \ bash procps grep gawk sed coreutils busybox-util-linux busybox-vi ldns libidn2-0 socat openssl curl \ + && zypper up -y \ && zypper "${ZYPPER_OPTIONS[@]}" clean --all ## Cleanup (reclaim approx 13 MiB): # None of this content should be relevant to the container: From 781757f086c580a5645ecbfb64e7dee22c92717a Mon Sep 17 00:00:00 2001 From: Dirk Wetter Date: Fri, 13 Oct 2023 17:32:35 +0200 Subject: [PATCH 2/2] polish phrasing --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index f672bf1..3767781 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,7 +11,7 @@ ARG INSTALL_ROOT # /etc/os-release provides $VERSION_ID below. # We don't need the openh264.repo and the non-oss repos, just costs build time (repo caches). # Also we need to remove the util_linux RPM to /really/ make sure busybox-util-linux gets installed. -# And we need to update, see PR #2424 +# And we need to run zypper update, see all PR #2424. RUN source /etc/os-release \ && rm -f /etc/zypp/repos.d/repo-openh264.repo /etc/zypp/repos.d/repo-non-oss.repo \ && export ZYPPER_OPTIONS=( --releasever "${VERSION_ID}" --installroot "${INSTALL_ROOT}" --cache-dir "${CACHE_ZYPPER}" ) \