feat: added docker support, added docker-compose.yml

This commit is contained in:
moonleay 2024-04-04 08:51:49 +02:00
parent 72a1fe8af3
commit cd879e8af9
Signed by: moonleay
GPG key ID: 82667543CCD715FB
3 changed files with 27 additions and 0 deletions

2
.dockerignore Normal file
View file

@ -0,0 +1,2 @@
/target
/data

10
Dockerfile Normal file
View file

@ -0,0 +1,10 @@
FROM rust:1.77
WORKDIR /usr/src/app
COPY . .
RUN apt-get update
RUN apt-get install -y cmake
RUN cargo build --release
CMD ["/usr/src/app/target/release/rustendo"]

15
docker-compose.yml Normal file
View file

@ -0,0 +1,15 @@
version: "3"
services:
botendo:
container_name: botendo
image: limiteddev/rustendo:0.1.0
environment:
TZ: "Europe/Berlin"
deploy:
resources:
limits:
cpus: "0.5"
memory: 512M
restart: unless-stopped
volumes:
- ./data:/usr/src/app/data