From c7cc85250b20015102447831d7ed1fe3660cb355 Mon Sep 17 00:00:00 2001 From: csaba-feher-sonarsource Date: Mon, 15 Apr 2024 16:06:07 +0200 Subject: [PATCH] SONAR-22089 Remove Python from installed libraries - Fix cacerts location --- 5/Dockerfile | 2 +- 5/bin/entrypoint.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/5/Dockerfile b/5/Dockerfile index b017cb6..f1496b4 100755 --- a/5/Dockerfile +++ b/5/Dockerfile @@ -20,7 +20,7 @@ RUN set -eux; \ addgroup -S -g 1000 scanner-cli; \ adduser -S -D -u 1000 -G scanner-cli scanner-cli; \ apk add --no-cache --virtual build-dependencies wget unzip gnupg; \ - apk add --no-cache git python3 py3-pip py3-pylint bash shellcheck "nodejs>=18" openjdk17-jre curl musl-locales musl-locales-lang; \ + apk add --no-cache git bash shellcheck "nodejs>=18" openjdk17-jre musl-locales musl-locales-lang; \ wget -U "scannercli" -q -O /opt/sonar-scanner-cli.zip https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${SONAR_SCANNER_VERSION}.zip; \ wget -U "scannercli" -q -O /opt/sonar-scanner-cli.zip.asc https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${SONAR_SCANNER_VERSION}.zip.asc; \ for server in $(shuf -e hkps://keys.openpgp.org \ diff --git a/5/bin/entrypoint.sh b/5/bin/entrypoint.sh index 2c929c0..7bec652 100755 --- a/5/bin/entrypoint.sh +++ b/5/bin/entrypoint.sh @@ -10,13 +10,13 @@ add_env_var_as_env_prop() { fi } -# If there are certificates in /tmp/cacers we will import those into the systems truststore +# If there are certificates in /tmp/cacerts we will import those into the systems truststore if [[ -d /tmp/cacerts ]]; then # shellcheck disable=SC2312 if [[ -n "$(ls -A /tmp/cacerts 2>/dev/null)" ]]; then for f in /tmp/cacerts/* do - keytool -importcert -file "${f}" -alias "$(basename "${f}")" -keystore /opt/java/openjdk/lib/security/cacerts -storepass changeit -trustcacerts -noprompt + keytool -importcert -file "${f}" -alias "$(basename "${f}")" -keystore /usr/lib/jvm/default-jvm/jre/lib/security/cacerts -storepass changeit -trustcacerts -noprompt done fi fi