shimen commited on
Commit
e27fffb
·
verified ·
1 Parent(s): 890c8b7

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -8
Dockerfile CHANGED
@@ -1,14 +1,12 @@
1
  FROM ghcr.io/open-webui/open-webui:main
2
 
3
- # Expose the port Open WebUI runs on
4
  EXPOSE 7860
5
 
6
- # Set environment variables
7
  ENV PORT=7860
8
- ENV WEBUI_SECRET_KEY=your-secret-key-here
9
- ENV DATA_DIR=/data
10
 
11
- # Create data directory
12
- RUN mkdir -p /data
13
-
14
- CMD ["bash", "-c", "cd /app/backend && exec uvicorn main:app --host 0.0.0.0 --port $PORT"]
 
1
  FROM ghcr.io/open-webui/open-webui:main
2
 
3
+ # Expose the port for Hugging Face Spaces
4
  EXPOSE 7860
5
 
6
+ # Set environment variables for HF Spaces
7
  ENV PORT=7860
8
+ ENV HOST=0.0.0.0
 
9
 
10
+ # Open WebUI runs on port 8080 by default, but HF Spaces needs 7860
11
+ # We'll use the built-in start script
12
+ CMD ["/bin/sh", "-c", "open-webui serve --port $PORT --host $HOST"]