-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathcompose.webhook.yml
More file actions
42 lines (38 loc) · 1.53 KB
/
compose.webhook.yml
File metadata and controls
42 lines (38 loc) · 1.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# This file is for extending the docker-compose.yml file in the getodk/central repo.
# From the getodk/central repo:
# docker compose -f docker-compose.yml -f /path/to/this/repo/compose.webhook.yml up -d
services:
# Add a healthcheck to the Central API service
service:
healthcheck:
test: nc -z localhost 8383 || exit 1
start_period: 15s
interval: 10s
timeout: 5s
retries: 10
# Override the image used to contain the `pgsql-http` extension and a healthcheck
postgres14:
image: "ghcr.io/hotosm/postgres:${POSTGRES_MAJOR:-14}-http"
healthcheck:
test: pg_isready -U ${DB_USER:-odk} || exit 1
start_period: 10s
interval: 5s
timeout: 5s
retries: 5
# The main webhook service
webhook:
image: "ghcr.io/hotosm/central-webhook:${CENTRAL_WEBHOOK_TAG:-latest}"
environment:
CENTRAL_WEBHOOK_DB_URI: postgresql://${DB_USER:-odk}:${DB_PASSWORD:-odk}@postgres14:5432/${DB_NAME:-odk}?sslmode=disable
CENTRAL_WEBHOOK_UPDATE_ENTITY_URL: ${CENTRAL_WEBHOOK_UPDATE_ENTITY_URL}
CENTRAL_WEBHOOK_REVIEW_SUBMISSION_URL: ${CENTRAL_WEBHOOK_REVIEW_SUBMISSION_URL}
CENTRAL_WEBHOOK_NEW_SUBMISSION_URL: ${CENTRAL_WEBHOOK_NEW_SUBMISSION_URL}
CENTRAL_WEBHOOK_API_KEY: ${CENTRAL_WEBHOOK_API_KEY}
CENTRAL_WEBHOOK_LOG_LEVEL: ${CENTRAL_WEBHOOK_LOG_LEVEL:-INFO}
# It waits for everything to be ready to install the trigger
depends_on:
postgres14:
condition: service_healthy
service:
condition: service_healthy
restart: on-failure