From 0d00d9b8bae68097018a340691766ad59d0a147b Mon Sep 17 00:00:00 2001 From: antifallobst Date: Fri, 24 Nov 2023 17:27:01 +0100 Subject: [PATCH] fix: fixed libssl not found error in docker image --- Dockerfile | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index aca8580..b937297 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,12 @@ +FROM debian:bullseye-slim as final + +RUN apt-get update; apt-get install -y libssl1.1; rm -rf /var/lib/apt/lists/* + FROM rust:latest as build RUN apt-get update; \ - apt-get install -y libclang-dev automake autoconf + apt-get install -y libclang-dev automake autoconf \ + openssl # 1. Create a new empty shell project RUN USER=root cargo new --bin nerdcult_api @@ -24,7 +29,7 @@ RUN rm ./target/release/deps/nerdcult_api* RUN SQLX_OFFLINE=true cargo build --release -FROM debian:bookworm-slim +FROM final COPY --from=build /nerdcult_api/target/release/nerdcult_api /bin/nerdcult_api