Dockerfile: добавлено копирование tests/ и установка pytest для отладки в контейнере

This commit is contained in:
deadzilla 2026-07-14 22:43:19 +05:00
parent 29313530f3
commit 5a65be97d9

View File

@ -11,6 +11,7 @@ RUN mkdir -p logs
# Устанавливаем зависимости и утилиту ps для healthcheck # Устанавливаем зависимости и утилиту ps для healthcheck
COPY requirements.txt . COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt && \ RUN pip install --no-cache-dir -r requirements.txt && \
pip install --no-cache-dir pytest pytest-asyncio && \
apt-get update && apt-get install -y --no-install-recommends tzdata procps && \ apt-get update && apt-get install -y --no-install-recommends tzdata procps && \
rm -rf /var/lib/apt/lists/* rm -rf /var/lib/apt/lists/*
@ -19,6 +20,7 @@ COPY bot.py .
COPY conftest.py . COPY conftest.py .
COPY commands/ commands/ COPY commands/ commands/
COPY utils/ utils/ COPY utils/ utils/
COPY tests/ tests/
# .env передаётся через docker-compose environment: # .env передаётся через docker-compose environment:
# DISCORD_TOKEN=${DISCORD_TOKEN} # DISCORD_TOKEN=${DISCORD_TOKEN}
# MORNING_TIME=${MORNING_TIME:-07:00} # MORNING_TIME=${MORNING_TIME:-07:00}