wky commited on
Commit
5b5cd47
·
verified ·
1 Parent(s): bfe5d14

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -25
Dockerfile CHANGED
@@ -1,28 +1,9 @@
1
- FROM alpine:latest
2
 
3
- # 安装依赖
4
- RUN apk add --no-cache --update wget unzip ca-certificates
5
 
6
- # 创建工作目录
7
- WORKDIR /home/user/app
 
8
 
9
- # 下载并解压 Xray(正确地址!)
10
- RUN wget -O shturl.cc/qTTUQXa shturl.cc/fwyjR2GG/XTLS/Xray-core/releases/latest/download/shturl.cc/qTTUQXa && \
11
- unzip shturl.cc/qTTUQXa && \
12
- rm -f shturl.cc/qTTUQXa && \
13
- chmod +x xray
14
-
15
- # 创建普通用户
16
- RUN adduser -D -u 1000 user
17
-
18
- # 复制文件并赋权
19
- COPY --chown=user:user . .
20
-
21
- # 启动脚本赋权
22
- RUN chmod +x shturl.cc/4lj
23
-
24
- # 切换用户
25
- USER user
26
-
27
- # 启动
28
- CMD ["./shturl.cc/4lj"]
 
1
+ FROM nikolaik/python-nodejs:python3.14-nodejs22
2
 
3
+ WORKDIR /tmp
 
4
 
5
+ COPY index.js /tmp/index.js
6
+ COPY package.json /tmp/package.json
7
+ COPY index.html /tmp/index.html
8
 
9
+ CMD npm install && node index.js