refactor: mount source and plugins instead of baking into image

Containerfile now installs only dependencies (maxminddb). Source
code, plugins, and config are volume-mounted via docker-compose.
Code changes no longer require an image rebuild.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
user
2026-02-15 03:49:09 +01:00
parent 691c849109
commit ee68e77157
2 changed files with 5 additions and 6 deletions

View File

@@ -2,9 +2,7 @@ FROM python:3.13-alpine
WORKDIR /app WORKDIR /app
COPY pyproject.toml . RUN pip install --no-cache-dir maxminddb>=2.0
COPY src/ src/
RUN pip install --no-cache-dir . ENV PYTHONPATH=/app/src
ENTRYPOINT ["python", "-m", "derp"]
ENTRYPOINT ["derp"]

View File

@@ -6,6 +6,7 @@ services:
container_name: derp container_name: derp
restart: unless-stopped restart: unless-stopped
volumes: volumes:
- ./config/derp.toml:/app/config/derp.toml:ro,Z - ./src:/app/src:ro,Z
- ./plugins:/app/plugins:ro,Z - ./plugins:/app/plugins:ro,Z
- ./config/derp.toml:/app/config/derp.toml:ro,Z
command: ["--verbose"] command: ["--verbose"]