FROM rust as builder
WORKDIR /opt/build
COPY . .
RUN cargo install --path .
FROM debian:bullseye-slim
WORKDIR /opt/data
COPY --from=builder /usr/local/cargo/bin/gitea-bot /bin/gitea-bot
CMD [ "gitea-bot" ]