11 lines
310 B
Docker
11 lines
310 B
Docker
# Stage 1: Build binary
|
|||
|
|
FROM rust:1.78-slim AS builder
|
||
|
|
WORKDIR /app
|
||
|
|
COPY . .
|
||
|
|
RUN cargo build --release
|
||
|
|
|
||
|
|
# Stage 2: Final minimal execution layer
|
||
|
|
FROM debian:bookworm-slim
|
||
|
|
WORKDIR /app
|
||
|
|
COPY --from=builder /app/target/release/huffman-compression-rust /app/huffman-compression-rust
|
||
|
|
ENTRYPOINT ["/app/my-rust-app"]
|