OrbitMC commited on
Commit
3510cb2
·
verified ·
1 Parent(s): 4b7180e

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +4 -6
Dockerfile CHANGED
@@ -1,17 +1,15 @@
1
- # Use a lightweight Python base
2
  FROM python:3.9-slim
3
 
4
- # Set working directory
5
  WORKDIR /app
6
 
7
- # Install dependencies directly
8
  RUN pip install --no-cache-dir flask flask-socketio eventlet gunicorn
9
 
10
- # Copy the application file
11
  COPY app.py .
12
 
13
- # Expose the port (Hugging Face Spaces uses 7860)
14
  EXPOSE 7860
15
 
16
- # Run the app using Gunicorn with Eventlet workers for WebSocket support
17
  CMD ["gunicorn", "--worker-class", "eventlet", "-w", "1", "--bind", "0.0.0.0:7860", "app:app"]
 
 
1
  FROM python:3.9-slim
2
 
 
3
  WORKDIR /app
4
 
5
+ # Install dependencies
6
  RUN pip install --no-cache-dir flask flask-socketio eventlet gunicorn
7
 
8
+ # Copy the application
9
  COPY app.py .
10
 
11
+ # Expose the port
12
  EXPOSE 7860
13
 
14
+ # Run with Gunicorn/Eventlet for WebSocket support
15
  CMD ["gunicorn", "--worker-class", "eventlet", "-w", "1", "--bind", "0.0.0.0:7860", "app:app"]