Add basic health check for db container

This commit is contained in:
Chris Thompson 2023-07-28 17:19:13 -04:00
parent cb2704731e
commit 1a2b3b9899
1 changed files with 6 additions and 0 deletions

View File

@ -84,6 +84,12 @@ services:
- "backupbot.backup.pre-hook=sh -c 'PGPASSWORD=$$(cat $${POSTGRES_PASSWORD_FILE}) pg_dump -U $${POSTGRES_USER} $${POSTGRES_DB} > /tmp/backup.sql'"
- "backupbot.backup.post-hook=rm -f /tmp/backup.sql"
- "backupbot.backup.path=/tmp/"
healthcheck:
test: "pg_isready"
interval: 30s
timeout: 10s
retries: 5
start_period: 1m
volumes:
postgres:
codimd_uploads: