ManiAz09 commited on
Commit
1ba3566
·
verified ·
1 Parent(s): 75a0eaa

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -19
Dockerfile CHANGED
@@ -1,22 +1,9 @@
1
- FROM ubuntu:22.04
2
-
3
- ENV DEBIAN_FRONTEND=noninteractive \
4
- TZ=UTC
5
-
6
- RUN apt-get update && apt-get install -y \
7
- curl \
8
- sudo \
9
- nginx \
10
- && rm -rf /var/lib/apt/lists/*
11
-
12
- # Install 3x-ui
13
- RUN bash <(curl -Ls https://raw.githubusercontent.com/mhsanaei/3x-ui/master/install.sh) dev-latest \
14
- && echo "Y" | x-ui enable
15
-
16
- # Copy start script
17
- COPY start.sh /start.sh
18
- RUN chmod +x /start.sh
19
 
 
 
20
  EXPOSE 7860
21
 
22
- CMD ["/start.sh"]
 
 
 
1
+ FROM ghcr.io/mhsanaei/3x-ui:latest
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
 
3
+ # Force the 3x-ui web panel to run on HF's allowed port
4
+ ENV X_UI_PORT=7860
5
  EXPOSE 7860
6
 
7
+ # Hugging Face requires running as a non-root user for security
8
+ RUN useradd -m -u 1000 user
9
+ USER user