Commit 704a0984 authored by 贾浩@五瓣科技's avatar 贾浩@五瓣科技

update healthcheck

parent 1cfb6e97
...@@ -13,6 +13,12 @@ services: ...@@ -13,6 +13,12 @@ services:
environment: environment:
MYSQL_ROOT_PASSWORD: "XN2UARuys3zy4Oux" MYSQL_ROOT_PASSWORD: "XN2UARuys3zy4Oux"
MYSQL_DATABASE: "sdk" MYSQL_DATABASE: "sdk"
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost", "-uroot", "--password=$$(cat $$MYSQL_ROOT_PASSWORD)"]
interval: 10s
timeout: 5s
retries: 5
start_period: 1s
sdk-api: sdk-api:
image: caduceus/ai-sdk-api:v0.0.2 image: caduceus/ai-sdk-api:v0.0.2
...@@ -20,7 +26,9 @@ services: ...@@ -20,7 +26,9 @@ services:
ports: ports:
- "16666:8080" - "16666:8080"
depends_on: depends_on:
- sdk-db sdk-db:
condition: service_healthy
volumes: volumes:
- ./conf/sdk-api/config.toml:/config.toml - ./conf/sdk-api/config.toml:/config.toml
command: command:
...@@ -36,7 +44,8 @@ services: ...@@ -36,7 +44,8 @@ services:
ports: ports:
- "16667:8080" - "16667:8080"
depends_on: depends_on:
- sdk-db sdk-db:
condition: service_healthy
volumes: volumes:
- ./conf/sdk-kv-api/config.toml:/config.toml - ./conf/sdk-kv-api/config.toml:/config.toml
command: command:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment