Update Dockerfile
Browse files- Dockerfile +6 -4
Dockerfile
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
FROM python:3.11-slim
|
| 2 |
|
| 3 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
| 4 |
-
|
| 5 |
|
| 6 |
RUN useradd -m -u 1000 user
|
| 7 |
USER user
|
|
@@ -13,10 +13,12 @@ WORKDIR /home/user/app
|
|
| 13 |
RUN pip install --no-cache-dir --upgrade pip && \
|
| 14 |
pip install --no-cache-dir torch --index-url https://download.pytorch.org/whl/cpu
|
| 15 |
|
| 16 |
-
|
|
|
|
|
|
|
| 17 |
|
| 18 |
-
#
|
| 19 |
-
RUN python -c "from
|
| 20 |
|
| 21 |
COPY --chown=user . /home/user/app
|
| 22 |
|
|
|
|
| 1 |
FROM python:3.11-slim
|
| 2 |
|
| 3 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
| 4 |
+
git ffmpeg libsndfile1 && rm -rf /var/lib/apt/lists/*
|
| 5 |
|
| 6 |
RUN useradd -m -u 1000 user
|
| 7 |
USER user
|
|
|
|
| 13 |
RUN pip install --no-cache-dir --upgrade pip && \
|
| 14 |
pip install --no-cache-dir torch --index-url https://download.pytorch.org/whl/cpu
|
| 15 |
|
| 16 |
+
# Hindi config ko "append_terminal_punctuation: false" chahiye, isliye GitHub ka latest pocket-tts
|
| 17 |
+
RUN pip install --no-cache-dir "git+https://github.com/kyutai-labs/pocket-tts.git" \
|
| 18 |
+
fastapi "uvicorn[standard]" numpy huggingface_hub
|
| 19 |
|
| 20 |
+
# config.yaml local folder me, weights aur tokenizer HF cache me (build time par hi download)
|
| 21 |
+
RUN python -c "from huggingface_hub import hf_hub_download as d; r='saryps-labs/pocket-tts-hindi'; d(r,'config.yaml',local_dir='/home/user/hindi_model'); d(r,'model.safetensors'); d(r,'tokenizer.model')" || true
|
| 22 |
|
| 23 |
COPY --chown=user . /home/user/app
|
| 24 |
|