-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
27 lines (19 loc) · 694 Bytes
/
Dockerfile
File metadata and controls
27 lines (19 loc) · 694 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
FROM python:3.13-slim AS builder
ENV PIP_DISABLE_PIP_VERSION_CHECK=1 \
PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1
WORKDIR /build
COPY . .
# Install the wheel into an isolated venv so only it (no build toolchain or
# source tree) is carried into the runtime stage.
RUN python -m venv /opt/venv \
&& /opt/venv/bin/pip install --no-cache-dir .
FROM python:3.13-slim
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1 \
PATH="/opt/venv/bin:$PATH"
COPY --from=builder /opt/venv /opt/venv
# /workspace is a mount point: `forerunner` runs against the caller's repo
# (Path.cwd()), bind-mounted here. Source is not baked in.
WORKDIR /workspace
ENTRYPOINT ["forerunner"]