Fix postgres healthcheck probing a nonexistent database

pg_isready without -d connects to a database named after the user, but
the database is imapcopier, so every probe logged a FATAL and the
healthcheck only passed because pg_isready treats "server rejects the
connection" as reachable.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-28 11:50:02 +07:00
co-authored by Claude Opus 5
parent 6bf3a6c4ca
commit 94fb410c59
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ services:
volumes:
- pgdata:/var/lib/postgresql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U imap imapcopier"]
test: ["CMD-SHELL", "pg_isready -U imap -d imapcopier"]
interval: 5s
timeout: 3s
retries: 5