Add Dockerfile.

This commit is contained in:
AB
2021-08-23 00:58:25 +03:00
parent d8b37b32df
commit f1dc1d0897
2 changed files with 16 additions and 1 deletions

3
.gitignore vendored
View File

@ -6,4 +6,5 @@ memory.sqlite3
/video
/voice
/.idea
Cargo.lock
Cargo.lock
k8s-deploy.yaml

14
Dockerfile Normal file
View File

@ -0,0 +1,14 @@
# syntax=docker/dockerfile:1
FROM rust:latest AS builder
WORKDIR /desubot
ADD ./ /desubot/
RUN cargo build --release
FROM ubuntu:latest
WORKDIR /storage
COPY --from=builder /desubot/target/release/desubot /usr/bin/
COPY mystem /usr/bin/
RUN apt update && apt install -y fontconfig openssl ca-certificates && rm -rf /var/lib/apt/lists/*
ENTRYPOINT desubot