tts-v0 / Dockerfile
darshankr's picture
Update Dockerfile
d50aebf verified
# Use Python 3.7 as base image
FROM python:3.7-slim
# Set the working directory inside the container
WORKDIR /app
# Install system dependencies
RUN apt-get update && apt-get install -y \
git \
python3-pip \
&& rm -rf /var/lib/apt/lists/*
# Copy the entire project, including the Indic-TTS directory, into the container
COPY . /app
# Verify that the Indic-TTS directory exists
RUN ls -al /app/Indic-TTS
# Install dependencies for Trainer and TTS
RUN cd /app/Indic-TTS/Trainer && \
python3 -m pip install -e .[all] && \
cd ../TTS && \
python3 -m pip install -e .[all] && \
cd .. && \
python3 -m pip install -r requirements.txt
# Install Gradio and upgrade to the latest version
RUN python3 -m pip install --upgrade gradio
# Create a writable directory for Gradio's flagging
RUN mkdir -p /app/flagged && \
chmod -R 777 /app/flagged
# Set the MPLCONFIGDIR environment variable to a writable directory
ENV MPLCONFIGDIR=/app/.config/matplotlib
# Set working directory back to /app
WORKDIR /app
# Set the default command to run your app
CMD ["python3", "app.py"]