Generate Docker image for backend

This commit is contained in:
Pierre HUBERT 2023-08-24 16:10:53 +02:00
parent a9ac04147d
commit 53c435881e
2 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,9 @@
FROM debian:bullseye-slim
RUN apt-get update \
&& apt-get install -y libcurl4 \
&& rm -rf /var/lib/apt/lists/*
COPY geneit_backend /usr/local/bin/geneit_backend
ENTRYPOINT /usr/local/bin/geneit_backend

View File

@ -0,0 +1,10 @@
#!/bin/bash
cargo build --release
TEMP_DIR=$(mktemp -d)
cp target/release/geneit_backend "$TEMP_DIR"
docker build -f Dockerfile "$TEMP_DIR" -t pierre42100/geneit_backend
rm -r $TEMP_DIR