Spaces:
Running
Running
Create dockerfile
Browse files- dockerfile +24 -0
dockerfile
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
FROM python:3.9-slim
|
2 |
+
|
3 |
+
# Install system dependencies
|
4 |
+
RUN apt-get update && apt-get install -y \
|
5 |
+
portaudio19-dev \
|
6 |
+
python3-pyaudio \
|
7 |
+
ffmpeg \
|
8 |
+
&& rm -rf /var/lib/apt/lists/*
|
9 |
+
|
10 |
+
# Set working directory
|
11 |
+
WORKDIR /app
|
12 |
+
|
13 |
+
# Copy requirements and install Python dependencies
|
14 |
+
COPY requirements.txt .
|
15 |
+
RUN pip install -r requirements.txt
|
16 |
+
|
17 |
+
# Copy application code
|
18 |
+
COPY . .
|
19 |
+
|
20 |
+
# Expose port
|
21 |
+
EXPOSE 7860
|
22 |
+
|
23 |
+
# Command to run the application
|
24 |
+
CMD ["python", "app.py"]
|