Add Dockerfile

This commit is contained in:
Jop Zitman 2024-12-10 16:58:56 +08:00
parent 9d309d48b1
commit 72eed3c2bb
3 changed files with 36 additions and 2 deletions

24
Dockerfile Normal file
View file

@ -0,0 +1,24 @@
FROM debian:bookworm-slim AS builder
WORKDIR /usr/src/app
# apt update without cache and install build-essential and cmake
RUN apt-get update && apt-get install -y build-essential cmake git pkg-config libssl-dev
COPY . .
RUN --mount=type=cache,target=/usr/src/app/cmake-cache \
cmake -Bcmake-cache -H. && \
cmake --build cmake-cache --target slipstream && mv cmake-cache/slipstream .
FROM debian:bookworm-slim
WORKDIR /usr/src/app
RUN apt-get update && apt-get install -y libssl3
COPY ./certs/ ./certs/
COPY --from=builder /usr/src/app/slipstream .
CMD ["/usr/src/app/slipstream"]