Murasame52 commited on
Commit
c6178aa
·
verified ·
1 Parent(s): b73fb73

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +11 -4
Dockerfile CHANGED
@@ -1,10 +1,17 @@
1
  # =============================================================================
2
- # Sub2API - 官方最新镜像 + 自定义启动脚本(补装 Python3
3
  # =============================================================================
4
  FROM ghcr.io/wei-shaw/sub2api:latest
5
 
6
- # 官方镜像可能基于 Alpine,补装 Python3 和 bcrypt(供脚本解析连接串和加密密码
7
- RUN apk add --no-cache python3 py3-bcrypt
 
 
 
 
 
 
 
8
 
9
  # 创建软链接,让脚本中的 /app/hub-gateway 指向实际的 /app/sub2api
10
  RUN ln -s /app/sub2api /app/hub-gateway
@@ -13,7 +20,7 @@ RUN ln -s /app/sub2api /app/hub-gateway
13
  COPY start-space.sh /app/start-space.sh
14
  RUN chmod +x /app/start-space.sh
15
 
16
- # 覆盖或补充环境变量默认值
17
  ENV SERVER_PORT=7860 \
18
  TZ=Asia/Shanghai
19
 
 
1
  # =============================================================================
2
+ # Sub2API - 官方最新镜像 + 自定义启动脚本(补全所有工具
3
  # =============================================================================
4
  FROM ghcr.io/wei-shaw/sub2api:latest
5
 
6
+ # 安装所有可能需要的工具(Alpine
7
+ RUN apk add --no-cache \
8
+ python3 \
9
+ py3-bcrypt \
10
+ redis \
11
+ postgresql-client \
12
+ openssl \
13
+ tzdata \
14
+ su-exec
15
 
16
  # 创建软链接,让脚本中的 /app/hub-gateway 指向实际的 /app/sub2api
17
  RUN ln -s /app/sub2api /app/hub-gateway
 
20
  COPY start-space.sh /app/start-space.sh
21
  RUN chmod +x /app/start-space.sh
22
 
23
+ # 环境变量默认值
24
  ENV SERVER_PORT=7860 \
25
  TZ=Asia/Shanghai
26