syw1516 commited on
Commit
ddfaee2
·
verified ·
1 Parent(s): eb1ee10

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +5 -7
Dockerfile CHANGED
@@ -1,4 +1,4 @@
1
- # 使用 Ubuntu 24.04 基础镜像(与 README 一致)
2
  FROM ubuntu:24.04
3
 
4
  ENV DEBIAN_FRONTEND=noninteractive
@@ -31,7 +31,7 @@ RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - \
31
  # 全局安装 openclaw
32
  RUN npm install -g openclaw@latest
33
 
34
- # 复制 entrypoint 脚本(转换换行符避免 exec format error)
35
  COPY scripts/openclaw-entrypoint.sh /tmp/openclaw-entrypoint.sh
36
  RUN dos2unix /tmp/openclaw-entrypoint.sh \
37
  && mv /tmp/openclaw-entrypoint.sh /usr/local/bin/openclaw-entrypoint.sh \
@@ -46,8 +46,6 @@ EXPOSE 7860
46
 
47
  WORKDIR /app
48
 
49
- # 使用 entrypoint 脚本作为入口
50
- ENTRYPOINT ["/usr/local/bin/openclaw-entrypoint.sh"]
51
-
52
- # 默认运行 gateway 子命令
53
- CMD ["gateway"]
 
1
+ # v=20260507b
2
  FROM ubuntu:24.04
3
 
4
  ENV DEBIAN_FRONTEND=noninteractive
 
31
  # 全局安装 openclaw
32
  RUN npm install -g openclaw@latest
33
 
34
+ # 复制 entrypoint 脚本(转换换行符)
35
  COPY scripts/openclaw-entrypoint.sh /tmp/openclaw-entrypoint.sh
36
  RUN dos2unix /tmp/openclaw-entrypoint.sh \
37
  && mv /tmp/openclaw-entrypoint.sh /usr/local/bin/openclaw-entrypoint.sh \
 
46
 
47
  WORKDIR /app
48
 
49
+ # 使用 bash -c 执行 entrypoint 脚本
50
+ ENTRYPOINT ["/bin/bash", "-c"]
51
+ CMD ["/usr/local/bin/openclaw-entrypoint.sh gateway"]