@@ -17,7 +17,7 @@ ARG UID=1200
1717ARG GID=1201
1818ARG TZ="UTC"
1919ARG JRE_VERSION=17
20- ARG TARGETARCH=amd64
20+ ARG TARGETARCH
2121ARG TARGETVARIANT
2222
2323USER root
@@ -36,10 +36,7 @@ ENV DEBIAN_FRONTEND=noninteractive \
3636# Miscellaneous packages
3737# Includes minimal runtime used for executing non GUI Java programs
3838# ========================
39- RUN echo "deb http://archive.ubuntu.com/ubuntu jammy main universe\n " > /etc/apt/sources.list \
40- && echo "deb http://archive.ubuntu.com/ubuntu jammy-updates main universe\n " >> /etc/apt/sources.list \
41- && echo "deb http://security.ubuntu.com/ubuntu jammy-security main universe\n " >> /etc/apt/sources.list \
42- && apt-get -qqy update \
39+ RUN apt-get -qqy update \
4340 && apt-get upgrade -yq \
4441 && apt-get -qqy --no-install-recommends install \
4542 acl \
@@ -107,14 +104,18 @@ RUN echo "deb http://archive.ubuntu.com/ubuntu jammy main universe\n" > /etc/ap
107104# =====
108105# Download observability related OpenTelemetry jars and make them available in a separate directory
109106# so that the container can skip downloading them everytime it comes up
110- # =====
111- && curl -fLo /tmp/cs https://github.com/coursier/launchers/raw/master/coursier \
112- && chmod +x /tmp/cs \
113- && mkdir -p /external_jars \
114- && chmod -R 775 /external_jars \
115- && /tmp/cs fetch --classpath --cache /external_jars \
116- io.opentelemetry:opentelemetry-exporter-otlp:${OPENTELEMETRY_VERSION} \
117- io.grpc:grpc-netty:${GRPC_VERSION} > /external_jars/.classpath.txt \
107+ # ===== \
108+ && if [ `arch` = "aarch64" ] || [ `arch` = "x86_64" ]; then \
109+ curl -fL https://github.com/coursier/launchers/raw/master/cs-`arch`-pc-linux.gz | gzip -d > /tmp/cs \
110+ && chmod +x /tmp/cs \
111+ && mkdir -p /external_jars \
112+ && chmod -R 775 /external_jars ; \
113+ fi \
114+ && if [ -f "/tmp/cs" ]; then \
115+ /tmp/cs fetch --classpath --cache /external_jars \
116+ io.opentelemetry:opentelemetry-exporter-otlp:${OPENTELEMETRY_VERSION} \
117+ io.grpc:grpc-netty:${GRPC_VERSION} > /external_jars/.classpath.txt ; \
118+ fi \
118119 && chmod 664 /external_jars/.classpath.txt \
119120 && rm -fr /root/.cache/* \
120121 # (Note that .bashrc is only executed in interactive bash shells.)
0 commit comments