From 812497208cfaca3b228daa9f88330fcbbefcb90c Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Thu, 29 Sep 2022 14:48:27 +0200 Subject: [PATCH] Fix SAP Machine debian repo key handling in pipeline MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- Dockerfile | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/Dockerfile b/Dockerfile index a31c683..4b7a56b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -115,20 +115,14 @@ ARG SAPMACHINE_VERSION=11.0.16.1 RUN set -ex \ && apt-get update \ - && apt-get install -y gnupg dirmngr --no-install-recommends \ + && apt-get install -y ca-certificates wget --no-install-recommends \ && rm -rf /var/lib/apt/lists/* \ - && for key in \ - CACB9FE09150307D1D22D82962754C3B3ABCFE23 \ - ; do \ - gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys "$key" || \ - gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$key" ; \ - gpg --batch --export --armor "$key" | tee /etc/apt/trusted.gpg.d/sapmachine-${key}.gpg.asc; \ - done \ + && wget -q -O - https://dist.sapmachine.io/debian/sapmachine.key | tee /etc/apt/trusted.gpg.d/sapmachine.gpg.asc \ && echo "deb http://dist.sapmachine.io/debian/amd64/ ./" | tee /etc/apt/sources.list.d/sapmachine.list \ && apt-get update \ && apt-get install -y sapmachine-$(echo ${SAPMACHINE_VERSION} | cut -d. -f1)-jdk=${SAPMACHINE_VERSION} --no-install-recommends \ && rm -rf /var/lib/apt/lists/* \ - && apt-get remove --purge --autoremove -y gnupg dirmngr \ + && apt-get remove --purge --autoremove -y ca-certificates wget \ # smoke test && java --version @@ -150,7 +144,7 @@ RUN set -ex \ && rm -f /tmp/apache-maven.tar.gz \ && ln -s ${MAVEN_HOME}/bin/mvn /usr/bin/mvn \ && chmod --recursive a+w "${MAVEN_HOME}"/conf/* \ - && apt-get remove --purge --autoremove -y curl \ + && apt-get remove --purge --autoremove -y ca-certificates curl \ # smoke test && mvn --version -- 2.34.1