summary refs log tree commit diff
path: root/Dockerfile
diff options
context:
space:
mode:
authorPaweł Dybiec <pawel@dybiec.info>2022-12-26 00:22:30 +0000
committerPaweł Dybiec <pawel@dybiec.info>2022-12-26 00:22:30 +0000
commit1386316b37bc19f2cf34c34861ec5862df0bd9ee (patch)
tree91144e04595f422505dcd9db0defea3831ffba66 /Dockerfile
parentAdd reply to method with example use-case (diff)
Add dockerfile and build/publish step for it
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile12
1 files changed, 12 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..a545eb1
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,12 @@
+FROM docker.io/rust:slim-bullseye as builder
+WORKDIR /app
+RUN apt update && apt install libssl-dev pkg-config -y
+RUN cargo install cargo-prefetch
+RUN cargo prefetch
+COPY Cargo* /app/
+COPY src /app/src
+RUN cargo build --release
+FROM docker.io/debian:bullseye-slim
+COPY --from=builder /app/target/release/vavbot /vavbot
+RUN apt update && apt install openssl ca-certificates -y
+CMD [ "/vavbot" ]
\ No newline at end of file