From 29a09e40cbdbd5cfc6d9d0527ff800d4f187b050 Mon Sep 17 00:00:00 2001 From: Songlin Jiang Date: Thu, 25 Apr 2024 12:45:50 +0300 Subject: [PATCH] Add linux/arm/v7 build to Docker CI Signed-off-by: Songlin Jiang --- .github/workflows/docker-publish.yml | 2 +- Dockerfile | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index 9a5e123..9506b30 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -69,4 +69,4 @@ jobs: fi echo IMAGE_ID=$IMAGE_ID echo VERSION=$VERSION - docker buildx build -t $IMAGE_ID:$VERSION --platform linux/amd64,linux/386,linux/arm64,linux/ppc64le --push . + docker buildx build -t $IMAGE_ID:$VERSION --platform linux/amd64,linux/386,linux/arm64,linux/arm/v7,linux/ppc64le --push . diff --git a/Dockerfile b/Dockerfile index d075f38..5945c4b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,10 @@ FROM rust as builder COPY . . RUN apt update && apt install -y build-essential +# Reference: https://github.com/rust-lang/cargo/issues/8719#issuecomment-1207488994 # Install mdbook -RUN cargo install --git https://github.com/HollowMan6/mdBook mdbook -RUN cargo install --path . +RUN --mount=type=tmpfs,target=/root/.cargo cargo install --git https://github.com/HollowMan6/mdBook mdbook +RUN --mount=type=tmpfs,target=/root/.cargo cargo install --path . FROM python as base RUN apt-get update \