# Voltlab Tradingbot – Software: Docker-Abbild (seit 14.11.2026, Phase 3)
# Wird beim Kunden gebaut:  docker compose up -d --build   (im entpackten Paket-Ordner)
# Alle Daten liegen im Ordner ./kibot-daten (Einstellungen, Konto, Journal, Schluessel, Lizenz, Versionen).
FROM python:3.12-slim-bookworm

ENV PYTHONUNBUFFERED=1 \
    PYTHONDONTWRITEBYTECODE=1 \
    KIBOT_DOCKER=1 \
    KIBOT_DATEN=/daten \
    KIBOT_BASIS=/daten \
    KIBOT_BUNDLED=/app/bundled \
    HOME=/daten/home \
    TZ=Europe/Zurich

WORKDIR /app
COPY pi/requirements.txt /app/requirements.txt
RUN pip install --no-cache-dir -r /app/requirements.txt
COPY . /app/bundled

EXPOSE 8080
VOLUME ["/daten"]
CMD ["python", "/app/bundled/kibot/starter.py"]
