Skip to content

Commit

Permalink
Merge pull request #164 from ckan/Update-healthcheck-to-Docker-Compose
Browse files Browse the repository at this point in the history
Update compose files to check the health of the CKAN and DataPusher container processes
  • Loading branch information
kowh-ai authored Oct 11, 2024
2 parents 01a91ea + fbef360 commit f62ff0c
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
6 changes: 6 additions & 0 deletions docker-compose.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,18 @@ services:
restart: unless-stopped
healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:5000"]
interval: 60s
timeout: 10s
retries: 3s

datapusher:
image: ckan/ckan-base-datapusher:${DATAPUSHER_VERSION}
restart: unless-stopped
healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:8800"]
interval: 60s
timeout: 10s
retries: 3s

db:
build:
Expand Down
8 changes: 7 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,10 @@ services:
- site_packages:/usr/lib/python3.10/site-packages
restart: unless-stopped
healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:5000"]
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:5000/api/action/status_show"]
interval: 60s
timeout: 10s
retries: 3

datapusher:
networks:
Expand All @@ -56,6 +59,9 @@ services:
restart: unless-stopped
healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:8800"]
interval: 60s
timeout: 10s
retries: 3

db:
build:
Expand Down

0 comments on commit f62ff0c

Please sign in to comment.