fix: offline deploy

This commit is contained in:
tao.chen
2026-08-17 15:30:21 +08:00
parent cbfbee7fe0
commit 0974881fbb
4 changed files with 16 additions and 9 deletions
+7 -6
View File
@@ -3,6 +3,7 @@ services:
build:
context: .
dockerfile: backend/Dockerfile
image: model-development-backend:latest
logging:
driver: json-file
options:
@@ -13,6 +14,7 @@ services:
- uv
- run
- --frozen
- --no-dev
- --package
- backend
- alembic
@@ -26,6 +28,7 @@ services:
build:
context: .
dockerfile: frontend/Dockerfile
image: model-development-web:latest
logging:
driver: json-file
options:
@@ -59,6 +62,7 @@ services:
build:
context: .
dockerfile: backend/Dockerfile
image: model-development-backend:latest
logging:
driver: json-file
options:
@@ -110,6 +114,7 @@ services:
build:
context: .
dockerfile: runtime/Dockerfile
image: model-development-runtime:latest
logging:
driver: json-file
options:
@@ -154,12 +159,7 @@ services:
# bind mount instead. In s3 mode the grep succeeds (mount must be up or
# startup would have crashed). In local mode the grep fails (no fuse.rclone)
# so the || branch runs: just verify /data/workspace is a directory.
test:
- CMD-SHELL
- |
grep -q ' /data/workspace .* - fuse.rclone ' /proc/self/mountinfo \
&& curl -fsS http://127.0.0.1:8000/api/v1/health \
|| { [ -d /data/workspace ] && curl -fsS http://127.0.0.1:8000/api/v1/health; }
test: [ "CMD-SHELL", "curl -fsS http://127.0.0.1:8000/api/v1/health >/dev/null" ]
interval: 10s
timeout: 5s
retries: 18
@@ -169,6 +169,7 @@ services:
build:
context: .
dockerfile: schedule/Dockerfile
image: model-development-schedule:latest
logging:
driver: json-file
options: