-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
28 lines (19 loc) · 986 Bytes
/
Copy pathDockerfile
File metadata and controls
28 lines (19 loc) · 986 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# ── Build stage ─────────────────────────────────────────────────────────────
FROM rust:slim AS builder
WORKDIR /build
RUN apt-get update && apt-get install -y pkg-config libssl-dev build-essential && \
rm -rf /var/lib/apt/lists/*
COPY Cargo.toml Cargo.lock ./
COPY src/ src/
RUN cargo build --release
# ── Runtime stage ───────────────────────────────────────────────────────────
FROM debian:bookworm-slim
RUN apt-get update && apt-get install -y ca-certificates && rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY --from=builder /build/target/release/peak-tracker ./
COPY static/ ./static/
COPY calendar-app/ ./calendar-app/
COPY entrypoint.sh ./
RUN chmod +x ./entrypoint.sh
EXPOSE 3000
ENTRYPOINT ["./entrypoint.sh"]