👷 Optimize building process using the homemade dioxus-cli docker image
All checks were successful
ci/woodpecker/push/dockerize Pipeline was successful
ci/woodpecker/push/deploy Pipeline was successful

This commit is contained in:
2024-04-15 23:18:40 +02:00
parent 6f95e0f57b
commit cae7a1e244
2 changed files with 5 additions and 3 deletions

View File

@@ -1,7 +1,9 @@
FROM rust:latest AS builder
ARG JOBS_NB=${JOBS_NB:-default}
# Homemade docker image providing the dioxus-cli
COPY --from=rg.fr-par.scw.cloud/asr-projects/dioxus-cli:asr-0.5.2 /usr/local/bin/dx /usr/local/bin/dx
ARG JOBS_NB=${JOBS_NB:-default}
# Disable incremental compilation
# Cf. https://doc.rust-lang.org/cargo/reference/profiles.html#incremental
ARG CARGO_INCREMENTAL=0
@@ -10,8 +12,7 @@ WORKDIR /usr/src/beau-gosse-du-92
COPY . .
RUN cargo install -j ${JOBS_NB} dioxus-cli
RUN dx build -r --platform web -- -j ${JOBS_NB}
RUN /usr/local/bin/dx build -r --platform web -- -j ${JOBS_NB}
FROM nginx:mainline-alpine-slim