From 249e02a0efcad153f5fa10d8c5d5b40adfde66cc Mon Sep 17 00:00:00 2001 From: Adi Muraru Date: Fri, 22 Dec 2023 18:20:59 +0200 Subject: [PATCH] Upgrade Kafka image to use Java v21 --- docker/kafka/Dockerfile | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/docker/kafka/Dockerfile b/docker/kafka/Dockerfile index f48bf0ed8..07b0b797f 100644 --- a/docker/kafka/Dockerfile +++ b/docker/kafka/Dockerfile @@ -36,22 +36,24 @@ RUN set -eux; \ ; \ rm -rf /var/lib/apt/lists/* -ENV JAVA_HOME /usr/local/openjdk-17 +ENV JAVA_HOME /usr/local/openjdk-21 ENV PATH $JAVA_HOME/bin:$PATH # Default to UTF-8 file.encoding ENV LANG C.UTF-8 +ENV JAVA_VERSION 21 + RUN set -eux; \ \ arch="$(dpkg --print-architecture)"; \ case "$arch" in \ 'amd64') \ - downloadUrl='https://download.oracle.com/java/17/latest/jdk-17_linux-x64_bin.tar.gz'; \ - downloadSha256='https://download.oracle.com/java/17/latest/jdk-17_linux-x64_bin.tar.gz.sha256'; \ + downloadUrl='https://download.oracle.com/java/21/latest/jdk-21_linux-x64_bin.tar.gz'; \ + downloadSha256='https://download.oracle.com/java/21/latest/jdk-21_linux-x64_bin.tar.gz.sha256'; \ ;; \ 'arm64') \ - downloadUrl='https://download.oracle.com/java/17/latest/jdk-17_linux-aarch64_bin.tar.gz'; \ - downloadSha256='https://download.oracle.com/java/17/latest/jdk-17_linux-aarch64_bin.tar.gz.sha256'; \ + downloadUrl='https://download.oracle.com/java/21/latest/jdk-21_linux-aarch64_bin.tar.gz'; \ + downloadSha256='https://download.oracle.com/java/21/latest/jdk-21_linux-aarch64_bin.tar.gz.sha256'; \ ;; \ *) echo >&2 "error: unsupported architecture: '$arch'"; exit 1 ;; \ esac; \