| FROM python:3.9 | |
| # Установка ffmpeg и системных зависимостей | |
| RUN apt-get update && apt-get install -y ffmpeg && rm -rf /var/lib/apt/lists/* | |
| WORKDIR /app | |
| COPY . . | |
| # Установка Python-зависимостей | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Явно скачиваем модель при сборке | |
| RUN python -c "from transformers import pipeline; pipeline('text-classification', model='cointegrated/rubert-tiny2-cedr-emotion-detection')" | |
| CMD ["gunicorn", "--bind", "0.0.0.0:8080", "app:app"] |