add dockerfile
This commit is contained in:
14
Dockerfile
Normal file
14
Dockerfile
Normal file
@@ -0,0 +1,14 @@
|
||||
FROM rust:1.77 as builder
|
||||
RUN mkdir /build
|
||||
WORKDIR /build
|
||||
COPY Cargo.toml Cargo.lock ./
|
||||
COPY src ./src
|
||||
RUN --mount=type=cache,target=/usr/local/cargo/registry \
|
||||
--mount=type=cache,target=/build/target \
|
||||
cargo build --release --bin blob-store-app && \
|
||||
cp target/release/blob-store-app /blob-store-app
|
||||
|
||||
FROM debian:bookworm-slim
|
||||
RUN apt-get update && apt-get install -qqy libsqlite3-0
|
||||
COPY --from=builder /blob-store-app /usr/local/bin/blob-store-server
|
||||
ENTRYPOINT ["blob-store-server", "--db-path", "/data", "--bind", "0.0.0.0"]
|
||||
Reference in New Issue
Block a user