From 7a0771215d9bd52dc9d6913abee56a9f62893d3e Mon Sep 17 00:00:00 2001 From: Anders Betts Date: Fri, 18 Sep 2026 10:24:32 +0200 Subject: deploy: cross-compile arm64 binaries on the dev machine The target only assembles the image from prebuilt binaries, so redeploys no longer compile sqlite/argon2 on the NAS. New deploy/Dockerfile.cross provides the gcc-aarch64-linux-gnu toolchain; the Dockerfile uses .prebuilt/ when present. --- Dockerfile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'Dockerfile') diff --git a/Dockerfile b/Dockerfile index d658d70..41e2895 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,7 +8,14 @@ RUN apt-get update \ && rm -rf /var/lib/apt/lists/* WORKDIR /src COPY . . -RUN make -j"$(nproc)" VERSION="$VERSION" && make test VERSION="$VERSION" +# With .prebuilt/ the binaries are cross-compiled on the development machine +# (see deploy/Dockerfile.cross); otherwise build and test from source. +RUN if [ -x .prebuilt/bokfd ]; then \ + mkdir -p build && \ + cp .prebuilt/bokfd .prebuilt/bokfctl .prebuilt/bokftui build/; \ + else \ + make -j"$(nproc)" VERSION="$VERSION" && make test VERSION="$VERSION"; \ + fi FROM debian:bookworm-slim AS runtime RUN apt-get update \ -- cgit v1.3