Fix mongosh, DCA price, compose healthcheck and cleanup

This commit is contained in:
yeasy
2026-04-27 14:17:57 +00:00
parent 04fd53ea3c
commit 37e376d578
7 changed files with 18 additions and 12 deletions
+1 -1
View File
@@ -26,7 +26,7 @@ Docker Compose 提供了丰富的命令来管理项目和容器。本节将详
**配置验证**
- `docker compose config`验证 docker-compose.yml 格式是否正确
- `docker compose config`验证 compose.yaml ( docker-compose.yml) 格式是否正确
### 11.4.1 命令对象与格式
@@ -5,6 +5,11 @@ services:
image: postgres
environment:
POSTGRES_PASSWORD: 'postgres'
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 5s
timeout: 5s
retries: 5
web:
build: .
@@ -13,3 +18,6 @@ services:
- .:/code
ports:
- "8000:8000"
depends_on:
db:
condition: service_healthy