We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb88b52 commit 8a8a904Copy full SHA for 8a8a904
1 file changed
docker-compose.yml
@@ -2,6 +2,12 @@ services:
2
db:
3
image: postgres:12
4
restart: always
5
+ healthcheck:
6
+ test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"]
7
+ interval: 10s
8
+ retries: 5
9
+ start_period: 30s
10
+ timeout: 10s
11
volumes:
12
- app-db-data:/var/lib/postgresql/data/pgdata
13
env_file:
@@ -42,7 +48,9 @@ services:
42
48
- traefik-public
43
49
- default
44
50
depends_on:
45
- - db
51
+ db:
52
+ condition: service_healthy
53
+ restart: true
46
54
47
55
- .env
56
environment:
0 commit comments