llzai commited on
Commit
dfcc2ac
·
verified ·
1 Parent(s): cd0b034

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +25 -27
Dockerfile CHANGED
@@ -1,28 +1,26 @@
1
- # Hugging Face Spaces Dockerfile for Octopus
2
- # 基于官方镜像 bestrui/octopus
3
-
4
- FROM bestrui/octopus:latest
5
-
6
- # 设置环境变量适配 Hugging Face Spaces
7
- # 注意: 必须设置 OCTOPUS_SERVER_PORT=7860,这是 Hugging Face Spaces 的要求
8
- ENV OCTOPUS_SERVER_HOST=0.0.0.0 \
9
- OCTOPUS_SERVER_PORT=7860 \
10
- OCTOPUS_DATABASE_TYPE=postgres \
11
- OCTOPUS_DATABASE_PATH=postgresql://postgres.zijaasxgmykkrhaazrcu:Sin2070zijaasxgmykkrhaazrcu@aws-1-ap-south-1.pooler.supabase.com:5432/postgres?sslmode=disable \
12
- OCTOPUS_LOG_LEVEL=info \
13
- TZ=Asia/Shanghai
14
-
15
- # 确保 data 目录存在 (Hugging Face Spaces 会自动持久化 /app/data)
16
- RUN mkdir -p /app/data
17
-
18
- # 暴露端口 (Hugging Face Spaces 使用 7860)
19
- EXPOSE 7860
20
-
21
- # 健康检查
22
- HEALTHCHECK --interval=30s --timeout=3s --start-period=10s --retries=3 \
23
- CMD wget --no-verbose --tries=1 --spider http://localhost:7860/ || exit 1
24
-
25
- # 启动命令
26
- # 原镜像已包含 /entrypoint.sh 脚本,该脚本会执行 ./octopus start
27
- # 也可以直接使用: CMD ["/app/octopus", "start"]
28
  CMD ["/entrypoint.sh"]
 
1
+ # Hugging Face Spaces Dockerfile for Octopus
2
+ # 基于官方镜像 bestrui/octopus
3
+
4
+ FROM bestrui/octopus:latest
5
+
6
+ # 设置环境变量适配 Hugging Face Spaces
7
+ # 注意: 必须设置 OCTOPUS_SERVER_PORT=7860,这是 Hugging Face Spaces 的要求
8
+ ENV OCTOPUS_SERVER_HOST=0.0.0.0 \
9
+ OCTOPUS_SERVER_PORT=7860 \
10
+ OCTOPUS_LOG_LEVEL=info \
11
+ TZ=Asia/Shanghai
12
+
13
+ # 确保 data 目录存在 (Hugging Face Spaces 会自动持久化 /app/data)
14
+ RUN mkdir -p /app/data
15
+
16
+ # 暴露端口 (Hugging Face Spaces 使用 7860)
17
+ EXPOSE 7860
18
+
19
+ # 健康检查
20
+ HEALTHCHECK --interval=30s --timeout=3s --start-period=10s --retries=3 \
21
+ CMD wget --no-verbose --tries=1 --spider http://localhost:7860/ || exit 1
22
+
23
+ # 启动命令
24
+ # 原镜像已包含 /entrypoint.sh 脚本,该脚本会执行 ./octopus start
25
+ # 也可以直接使用: CMD ["/app/octopus", "start"]
 
 
26
  CMD ["/entrypoint.sh"]