- Increase start_period from 5s to 10s to allow more time for service initialization - Change health check URL from localhost to 127.0.0.1 for better compatibility
18 lines
374 B
YAML
18 lines
374 B
YAML
version: '3.8'
|
|
services:
|
|
web:
|
|
build: .
|
|
ports:
|
|
- "3000:3000"
|
|
volumes:
|
|
- ./data:/app/data
|
|
environment:
|
|
- PORT=3000
|
|
- NODE_ENV=production
|
|
healthcheck:
|
|
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://127.0.0.1:3000/health"]
|
|
interval: 30s
|
|
timeout: 3s
|
|
retries: 3
|
|
start_period: 10s
|