Fix healthcheck and environment variables in docker-compose.yml

This commit is contained in:
tiltshiftfocus
2025-05-20 14:50:35 +08:00
committed by GitHub
parent 63d9abfe3e
commit 5a44d79279

View File

@@ -10,7 +10,7 @@ services:
environment:
- PORT=${API_INTERNAL_PORT:-3333} # Port for the backend service
- DATABASE_URL=postgresql://postgres:${POSTGRESQL_PASSWORD:-postgresRootPassword}@postgres:5432/palmr_db?schema=public # Database URL with configurable password through POSTGRESQL_PASSWORD env var
- MINIO_ENDPOINT=minio # This can change if your MinIO is at a different address
- MINIO_ENDPOINT=${MINIO_ENDPOINT:-minio} # This can change if your MinIO is at a different address
- MINIO_PORT=${MINIO_INTERNAL_API_PORT:-6421} # Default MinIO port (Change if yours is not the default)
- MINIO_USE_SSL=false # MinIO uses SSL by default, but you can change it to true if needed
- MINIO_ROOT_USER=${MINIO_ROOT_USER:-minio_root_user} # MinIO credentials can be configured through MINIO_ROOT_USER env vars
@@ -24,7 +24,7 @@ services:
- "${API_EXTERNAL_PORT:-3333}:${API_INTERNAL_PORT:-3333}" # Backend port mapping
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:${API_INTERNAL_PORT:-3333}/health"]
test: ["CMD", "wget", "--no-verbose", "http://palmr-api:${API_INTERNAL_PORT:-3333}/health"]
interval: 10s
timeout: 5s
retries: 5