From 836db82c5ffa99ca64fff975874fcff99c81c8ae Mon Sep 17 00:00:00 2001 From: Dany Sluijk Date: Fri, 6 Dec 2024 08:12:50 +0100 Subject: [PATCH] fix: correctly compile and output the docker image --- Dockerfile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 8fdac73..e0ec625 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,13 +1,14 @@ -FROM rust:latest AS builder +FROM rust:alpine AS builder WORKDIR /app +RUN apk update && apk upgrade +RUN apk add libc-dev openssl-dev openssl-libs-static COPY ./Cargo.toml ./Cargo.lock ./ COPY ./src ./src RUN cargo build --release -RUN mv ./target/release/JollyFellow ./app -FROM rust:1-alpine3.20 +FROM alpine WORKDIR /app -COPY --from=builder /app/app /usr/local/bin/ -CMD ["/usr/local/bin/app"] \ No newline at end of file +COPY --from=builder /app/target/release/JollyFellow /usr/local/bin/jollyfellow +CMD ["jollyfellow"] \ No newline at end of file