Skip to content

Commit a61ced8

Browse files
committed
fix glitchtip healthchecks
1 parent f10dea2 commit a61ced8

File tree

1 file changed

+17
-7
lines changed

1 file changed

+17
-7
lines changed

templates/compose/glitchtip.yaml

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,28 @@ services:
1212
- POSTGRES_PASSWORD=${SERVICE_PASSWORD_POSTGRESQL}
1313
- POSTGRES_DB=${POSTGRESQL_DATABASE:-glitchtip}
1414
volumes:
15-
- pg-data:/var/lib/postgresql/data
15+
- glitchtip-postgres-data:/var/lib/postgresql/data
1616
healthcheck:
1717
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
1818
interval: 5s
1919
timeout: 20s
2020
retries: 10
21+
2122
redis:
2223
image: redis
2324
healthcheck:
2425
test: ["CMD", "redis-cli", "ping"]
2526
interval: 5s
2627
timeout: 20s
2728
retries: 10
29+
2830
web:
2931
image: glitchtip/glitchtip
3032
depends_on:
31-
- postgres
32-
- redis
33+
postgres:
34+
condition: service_healthy
35+
redis:
36+
condition: service_healthy
3337
environment:
3438
- SERVICE_FQDN_GLITCHTIP_8080
3539
- DATABASE_URL=postgres://$SERVICE_USER_POSTGRESQL:$SERVICE_PASSWORD_POSTGRESQL@postgres:5432/${POSTGRESQL_DATABASE:-glitchtip}
@@ -46,12 +50,15 @@ services:
4650
interval: 5s
4751
timeout: 20s
4852
retries: 10
53+
4954
worker:
5055
image: glitchtip/glitchtip
5156
command: ./bin/run-celery-with-beat.sh
5257
depends_on:
53-
- postgres
54-
- redis
58+
postgres:
59+
condition: service_healthy
60+
redis:
61+
condition: service_healthy
5562
environment:
5663
- DATABASE_URL=postgres://$SERVICE_USER_POSTGRESQL:$SERVICE_PASSWORD_POSTGRESQL@postgres:5432/${POSTGRESQL_DATABASE:-glitchtip}
5764
- SECRET_KEY=$SERVICE_BASE64_64_ENCRYPTION
@@ -67,12 +74,15 @@ services:
6774
interval: 5s
6875
timeout: 20s
6976
retries: 10
77+
7078
migrate:
7179
image: glitchtip/glitchtip
7280
restart: "no"
7381
depends_on:
74-
- postgres
75-
- redis
82+
postgres:
83+
condition: service_healthy
84+
redis:
85+
condition: service_healthy
7686
command: "./manage.py migrate"
7787
environment:
7888
- DATABASE_URL=postgres://$SERVICE_USER_POSTGRESQL:$SERVICE_PASSWORD_POSTGRESQL@postgres:5432/${POSTGRESQL_DATABASE:-glitchtip}

0 commit comments

Comments
 (0)