-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathDockerfile
More file actions
32 lines (25 loc) · 912 Bytes
/
Copy pathDockerfile
File metadata and controls
32 lines (25 loc) · 912 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
FROM python:3.12-slim
# ffmpeg нужен для голосовых/audio (faster-whisper умеет webm/ogg через ffmpeg)
# libgomp1 — рантайм OpenMP для ctranslate2 (внутри faster-whisper)
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
ffmpeg \
libgomp1 \
ca-certificates \
tzdata \
&& rm -rf /var/lib/apt/lists/*
ENV PYTHONUNBUFFERED=1 \
PYTHONDONTWRITEBYTECODE=1 \
PIP_NO_CACHE_DIR=1 \
PIP_DISABLE_PIP_VERSION_CHECK=1 \
XDG_CACHE_HOME=/app/data/cache \
HF_HOME=/app/data/cache/huggingface
WORKDIR /app
COPY requirements.txt ./
RUN pip install --upgrade pip \
&& pip install -r requirements.txt
COPY src/ ./src/
COPY main.py ./
# data — монтируется томом снаружи (БД, сессии, qdrant, media, кэш моделей)
RUN mkdir -p /app/data
CMD ["python", "main.py"]