Merge pull request 'compose: declare the healthcheck that the image already has' (#16) from podman-healthcheck into main
Reviewed-on: #16
This commit is contained in:
commit
8de75012ad
1 changed files with 8 additions and 0 deletions
|
|
@ -4,6 +4,14 @@ services:
|
||||||
build: .
|
build: .
|
||||||
image: datacenterbingo:latest
|
image: datacenterbingo:latest
|
||||||
container_name: datacenterbingo
|
container_name: datacenterbingo
|
||||||
|
# Same as the image HEALTHCHECK. Podman ignores HEALTHCHECK in OCI-format
|
||||||
|
# images (what kaniko pushes), and the deploy waits for "healthy".
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL","ruby -rnet/http -e 'port = ENV.fetch(\"PUMA_PORT\", \"3000\"); exit(Net::HTTP.get_response(URI(\"http://127.0.0.1:#{port}/healthz\")).code == \"200\" ? 0 : 1)'"]
|
||||||
|
interval: 30s
|
||||||
|
timeout: 5s
|
||||||
|
start_period: 20s
|
||||||
|
retries: 3
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
env_file: .env
|
env_file: .env
|
||||||
networks:
|
networks:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue