Skip to content

Commit

Permalink
Added postgis service's pg_isready healthcheck with external ip in do…
Browse files Browse the repository at this point in the history
…cker-compose.yml
  • Loading branch information
sanak committed Jun 7, 2022
1 parent c233dd5 commit 7424f51
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ services:
POSTGRES_DB: ${DB_NAME}
volumes:
- postgis:/var/lib/postgresql/data
healthcheck:
test: "pg_isready -h postgis -U ${DB_USER} -d ${DB_NAME}"
interval: 10s
timeout: 2s
retries: 5
start_period: 10s

redmine:
build:
Expand All @@ -22,7 +28,8 @@ services:
- ./plugins:/usr/src/redmine/plugins
- ./public/themes:/usr/src/redmine/public/themes
depends_on:
- postgis
postgis:
condition: service_healthy

volumes:
postgis:

0 comments on commit 7424f51

Please sign in to comment.