Spaces:
Sleeping
Sleeping
File size: 991 Bytes
bd19c15 |
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 33 34 35 36 37 38 |
FROM python:3.10-slim
# Set environment variables
ENV PIP_NO_CACHE_DIR=true \
PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1 \
NUMBA_DISABLE_CACHE=1
# Install system dependencies
RUN apt-get update && apt-get install -y \
git ffmpeg libsndfile1 build-essential python3-dev libffi-dev wget curl \
&& apt-get clean
# Set workdir
WORKDIR /app
# Copy project files
COPY app.py app.py
COPY requirements.txt requirements.txt
# Install Python build tools first
RUN pip install --upgrade pip setuptools wheel
# Fix numpy for numba compatibility
RUN pip install numpy==1.24.3
# Install whisper manually from GitHub
RUN pip install git+https://github.com/openai/whisper.git
# Install all other requirements except TTS
RUN pip install -r requirements.txt
# Install Coqui TTS separately (after dependencies)
RUN pip install git+https://github.com/coqui-ai/TTS.git
# Run the Streamlit app
CMD ["streamlit", "run", "app.py", "--server.port=7860", "--server.address=0.0.0.0"]
|