@@ -22,7 +22,7 @@ RUN moon run frontend:build transactional:build
22
22
RUN moon docker prune
23
23
24
24
FROM --platform=$BUILDPLATFORM lukemathwalker/cargo-chef AS backend-chef
25
- RUN apt-get update && apt-get install -y --no-install-recommends gcc-aarch64-linux-gnu libc6-dev-arm64-cross clang llvm ca-certificates
25
+ RUN apt-get update && apt-get install -y --no-install-recommends gcc-aarch64-linux-gnu libc6-dev-arm64-cross clang llvm ca-certificates pkg-config make g++ libssl-dev
26
26
RUN update-ca-certificates
27
27
WORKDIR app
28
28
@@ -32,7 +32,6 @@ RUN cargo chef prepare --recipe-path recipe.json
32
32
33
33
FROM backend-chef AS backend-builder
34
34
# build specific
35
- ARG TARGETARCH
36
35
ARG BUILD_PROFILE=release
37
36
# application specific
38
37
ARG APP_VERSION
@@ -41,15 +40,8 @@ ARG DEFAULT_MAL_CLIENT_ID
41
40
RUN test -n "$APP_VERSION" && \
42
41
test -n "$DEFAULT_TMDB_ACCESS_TOKEN" && \
43
42
test -n "$DEFAULT_MAL_CLIENT_ID"
44
- ENV RUST_TARGET_TRIPLE_arm64="aarch64-unknown-linux-gnu"
45
- ENV RUST_TARGET_TRIPLE_amd64="x86_64-unknown-linux-gnu"
46
- ENV TARGET_CC="clang"
47
- ENV TARGET_AR="llvm-ar"
48
- ENV CFLAGS_aarch64_unknown_linux_gnu="--sysroot=/usr/aarch64-linux-gnu"
49
- ENV CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc
50
43
COPY --from=backend-planner /app/recipe.json recipe.json
51
- RUN rustup target add $(eval "echo \$ RUST_TARGET_TRIPLE_$TARGETARCH" )
52
- RUN cargo chef cook --profile $BUILD_PROFILE --target $(eval "echo \$ RUST_TARGET_TRIPLE_$TARGETARCH" ) --recipe-path recipe.json
44
+ RUN cargo chef cook --profile $BUILD_PROFILE --recipe-path recipe.json
53
45
COPY . .
54
46
COPY --from=frontend-builder /app/apps/backend/templates ./apps/backend/templates
55
47
RUN APP_VERSION=$APP_VERSION \
0 commit comments