Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,4 @@ COPY --from=useradd /etc/group /etc/group
COPY --from=useradd /etc/passwd /etc/passwd
COPY --from=certs /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
USER nonroot:nonroot
ENTRYPOINT ["/app/centralwebhook"]
ENTRYPOINT ["/app/centralwebhook", "install"]
18 changes: 13 additions & 5 deletions compose.webhook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,31 @@ services:
timeout: 5s
retries: 10

# Override the image used to contain the `pgsql-http` extension
# Override the image used to contain the `pgsql-http` extension and a healthcheck
postgres14:
image: "ghcr.io/hotosm/postgres: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:0.2.0"
image: "ghcr.io/hotosm/central-webhook:1.0.2"
environment:
CENTRAL_WEBHOOK_DB_URI: postgresql://odk:odk@postgres14:5432/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_started
condition: service_healthy
service:
condition: service_started
restart: always
condition: service_healthy
restart: on-failure