File size: 657 Bytes
882dc25
32107fd
 
5f297ac
 
 
06ac8fe
 
f2ac968
 
 
 
06ac8fe
32107fd
06ac8fe
32107fd
06ac8fe
32107fd
 
06ac8fe
32107fd
 
06ac8fe
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Use a stable, official Python image
FROM python:3.10-slim

# Set the working directory
WORKDIR /app

# Install system dependencies for audio package compilation
RUN apt-get update && apt-get install -y \
    build-essential \
    portaudio19-dev \
    && rm -rf /var/lib/apt/lists/*

# Copy requirements and install them
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

# Copy the application code and credentials
COPY . .

# Expose the port that Hugging Face will route to
EXPOSE 7860

# Command to run the Flask application using a production WSGI server
CMD ["gunicorn", "--bind", "0.0.0.0:7860", "--workers", "4", "app:app"]