feat: code quality audit + autoresearch integration + infra hardening (#150)
This commit is contained in:
committed by
GitHub
parent
fd0ede0d51
commit
ae3bb1cc21
15
Dockerfile
15
Dockerfile
@@ -11,7 +11,7 @@
|
||||
# timmy-time:latest \
|
||||
# python -m swarm.agent_runner --agent-id w1 --name Worker-1
|
||||
|
||||
# ── Stage 1: Builder — export deps via Poetry, install via pip ──────────────
|
||||
# ── Stage 1: Builder — install deps via Poetry ──────────────────────────────
|
||||
FROM python:3.12-slim AS builder
|
||||
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
@@ -20,18 +20,15 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
|
||||
WORKDIR /build
|
||||
|
||||
# Install Poetry + export plugin (only needed for export, not in runtime)
|
||||
RUN pip install --no-cache-dir poetry poetry-plugin-export
|
||||
# Install Poetry (only needed to resolve deps, not in runtime)
|
||||
RUN pip install --no-cache-dir poetry
|
||||
|
||||
# Copy dependency files only (layer caching)
|
||||
COPY pyproject.toml poetry.lock ./
|
||||
|
||||
# Export pinned requirements and install with pip cache mount
|
||||
RUN poetry export --extras swarm --extras telegram --extras discord --without-hashes \
|
||||
-f requirements.txt -o requirements.txt
|
||||
|
||||
RUN --mount=type=cache,target=/root/.cache/pip \
|
||||
pip install --no-cache-dir -r requirements.txt
|
||||
# Install deps directly from lock file (no virtualenv, no export plugin needed)
|
||||
RUN poetry config virtualenvs.create false && \
|
||||
poetry install --only main --extras telegram --extras discord --no-interaction
|
||||
|
||||
# ── Stage 2: Runtime ───────────────────────────────────────────────────────
|
||||
FROM python:3.12-slim AS base
|
||||
|
||||
Reference in New Issue
Block a user