From f5798203ddcda968caba77bc40349706d12314b7 Mon Sep 17 00:00:00 2001 From: Zastian Pretorius Date: Fri, 10 May 2024 12:27:19 +0100 Subject: [PATCH] added dockerfile to make a docker image --- Dockerfile | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..de21090 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,13 @@ +FROM rust:latest as builder +WORKDIR /usr/src/methoddata +COPY . . +RUN apt-get update && apt-get install -y libssl-dev pkg-config +RUN rustup target add x86_64-unknown-linux-gnu +RUN cargo build --release --target x86_64-unknown-linux-gnu + +FROM debian:bookworm-slim +WORKDIR /usr/local/bin/ +RUN apt-get update && apt-get install -y libssl3 curl +COPY --from=builder /usr/src/methoddata/target/x86_64-unknown-linux-gnu/release/methoddata . +COPY public /public +CMD ["./methoddata"] \ No newline at end of file