Update Dockerfile
Browse files- Dockerfile +17 -15
Dockerfile
CHANGED
|
@@ -1,27 +1,29 @@
|
|
|
|
|
| 1 |
FROM python:3.10-slim
|
| 2 |
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
# Depend锚ncias do sistema para build e TTS
|
| 6 |
RUN apt-get update && apt-get install -y \
|
| 7 |
git \
|
|
|
|
| 8 |
ffmpeg \
|
| 9 |
-
build-essential \
|
| 10 |
-
cmake \
|
| 11 |
-
libsndfile1 \
|
| 12 |
-
libopenblas-dev \
|
| 13 |
-
libffi-dev \
|
| 14 |
-
python3-dev \
|
| 15 |
&& rm -rf /var/lib/apt/lists/*
|
| 16 |
|
| 17 |
-
#
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21 |
|
| 22 |
-
#
|
| 23 |
-
|
|
|
|
| 24 |
|
|
|
|
| 25 |
EXPOSE 8000
|
| 26 |
|
|
|
|
| 27 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "8000"]
|
|
|
|
| 1 |
+
# Usando Python 3.10 slim
|
| 2 |
FROM python:3.10-slim
|
| 3 |
|
| 4 |
+
# Instalar depend锚ncias do sistema
|
|
|
|
|
|
|
| 5 |
RUN apt-get update && apt-get install -y \
|
| 6 |
git \
|
| 7 |
+
wget \
|
| 8 |
ffmpeg \
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
&& rm -rf /var/lib/apt/lists/*
|
| 10 |
|
| 11 |
+
# Definir diret贸rio de trabalho
|
| 12 |
+
WORKDIR /app
|
| 13 |
+
|
| 14 |
+
# Copiar arquivos
|
| 15 |
+
COPY requirements.txt .
|
| 16 |
+
COPY app.py .
|
| 17 |
+
|
| 18 |
+
# Instalar depend锚ncias Python
|
| 19 |
+
RUN pip install --no-cache-dir -r requirements.txt
|
| 20 |
|
| 21 |
+
# Clonar F5-TTS
|
| 22 |
+
RUN git clone https://github.com/SWivid/F5-TTS.git f5_tts_repo
|
| 23 |
+
RUN pip install --no-cache-dir ./f5_tts_repo
|
| 24 |
|
| 25 |
+
# Expor porta do FastAPI
|
| 26 |
EXPOSE 8000
|
| 27 |
|
| 28 |
+
# Comando para iniciar FastAPI
|
| 29 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "8000"]
|