Browse Source

Merge pull request #6812 from Budibase/fix/single-image-health

Quick healthcheck update for single image
master
Michael Drury 4 years ago
committed by GitHub
parent
commit
9e7bd652d9
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      hosting/single/Dockerfile
  2. 4
      hosting/single/healthcheck.sh

2
hosting/single/Dockerfile

@ -108,7 +108,7 @@ RUN chmod +x install.sh && ./install.sh
WORKDIR /
ADD hosting/single/runner.sh .
RUN chmod +x ./runner.sh
ADD hosting/scripts/healthcheck.sh .
ADD hosting/single/healthcheck.sh .
RUN chmod +x ./healthcheck.sh
ADD hosting/scripts/build-target-paths.sh .

4
hosting/scripts/healthcheck.sh → hosting/single/healthcheck.sh

@ -1,6 +1,10 @@
#!/usr/bin/env bash
healthy=true
if [ -f "/data/.env" ]; then
export $(cat /data/.env | xargs)
fi
if [[ $(curl -Lfk -s -w "%{http_code}\n" http://localhost/ -o /dev/null) -ne 200 ]]; then
echo 'ERROR: Budibase is not running';
healthy=false
Loading…
Cancel
Save