Files
bouncer/Containerfile
user 2b893969d2
All checks were successful
CI / secrets (push) Successful in 8s
CI / lint (push) Successful in 11s
CI / test (push) Successful in 26s
CI / build (push) Successful in 31s
fix: switch to alpine base image and upgrade pip
Replace python:3.12-slim (Debian) with python:3.12-alpine to reduce
image size and eliminate 68 Debian-inherited CVEs. Upgrade pip to
resolve CVE-2025-8869. Build deps installed temporarily for native
extensions (cryptography) and removed after pip install.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 12:54:16 +01:00

21 lines
455 B
Docker

FROM python:3.12-alpine
WORKDIR /app
COPY requirements.txt .
RUN apk add --no-cache --virtual .build gcc musl-dev libffi-dev openssl-dev && \
pip install --no-cache-dir --upgrade pip && \
pip install --no-cache-dir -r requirements.txt && \
apk del .build
COPY src/ /app/src/
ENV PYTHONUNBUFFERED=1
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONPATH=/app/src
VOLUME /data
ENTRYPOINT ["python", "-m", "bouncer"]
CMD ["-c", "/data/bouncer.toml"]