VictoriaMetrics/deployment/docker/builder/Dockerfile
Andrii Chubatiuk 29f9b8ef5d
deployment/docker: allow cross-platform building on arm64 platform (#6158)
Added x86_64 libraries to allow building cross-platform images on arm64

(cherry picked from commit 7958f38864)
2024-04-23 14:52:30 +02:00

14 lines
480 B
Docker

ARG go_builder_image
FROM $go_builder_image
STOPSIGNAL SIGINT
RUN apk add git gcc musl-dev make wget --no-cache && \
mkdir /opt/cross-builder && \
cd /opt/cross-builder && \
for arch in aarch64 x86_64; do \
wget \
https://musl.cc/${arch}-linux-musl-cross.tgz \
-O /opt/cross-builder/${arch}-musl.tgz \
--no-verbose && \
tar zxf ${arch}-musl.tgz -C ./ && \
rm /opt/cross-builder/${arch}-musl.tgz; \
done