sanbo commited on
Commit
14ad3bf
·
1 Parent(s): 07d65bb

update sth. at 2024-10-30 12:50:14

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -8
Dockerfile CHANGED
@@ -4,15 +4,13 @@ FROM ghcr.io/aurora-develop/duck2api:latest
4
  # 安装 socat
5
  RUN apk add --no-cache socat
6
 
 
 
 
 
 
7
  # 暴露对外端口 7680
8
  EXPOSE 7680
9
 
10
-
11
- COPY . .
12
-
13
- # 拷贝启动脚本到正确的目录
14
- COPY --from=0 /start.sh /start.sh
15
-
16
-
17
  # 设置启动命令
18
- CMD ["/start.sh"]
 
4
  # 安装 socat
5
  RUN apk add --no-cache socat
6
 
7
+ # 创建启动脚本并确保路径正确
8
+ RUN echo '#!/bin/sh\n\
9
+ socat TCP-LISTEN:7680,fork TCP:localhost:8080 &\n\
10
+ exec /app/duck2api' > /start.sh && chmod +x /start.sh
11
+
12
  # 暴露对外端口 7680
13
  EXPOSE 7680
14
 
 
 
 
 
 
 
 
15
  # 设置启动命令
16
+ CMD ["/start.sh"]