https://dev.kronoz.win/r/rgit.git
1FROM rust:1.71-slim AS builder
2
3RUN rustup component add rustfmt
4RUN apt-get update && apt-get install -y libssl-dev pkg-config clang
5
6COPY . /sources
7WORKDIR /sources
8RUN cargo build --release
9
10FROM debian:bullseye-slim
11
12# Install git and cleanup package lists.
13# This is required for git-http-backend to work.
14RUN apt-get update && \
15 apt-get install -y git && \
16 rm -rf /var/lib/apt/lists/*
17
18COPY --from=builder /sources/target/release/rgit /rgit
19
20COPY ./scripts/docker/entrypoint.sh .
21RUN chmod +x entrypoint.sh
22
23EXPOSE 8000
24ENTRYPOINT ["/entrypoint.sh"]