Merge pull request #84 from michaelkrieger/patch-1

Permit the healthcheck to work if a BASE_PATH is set
pull/1081/head
Adam 2021-12-18 13:47:59 +00:00 committed by GitHub
commit 423837f172
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -60,9 +60,10 @@ ENV IS_DOCKER=true
ENV SASS=/usr/local/bin/sassc ENV SASS=/usr/local/bin/sassc
ENV STATPING_DIR=/app ENV STATPING_DIR=/app
ENV PORT=8080 ENV PORT=8080
ENV BASE_PATH=""
EXPOSE $PORT EXPOSE $PORT
HEALTHCHECK --interval=60s --timeout=10s --retries=3 CMD curl -s "http://localhost:$PORT/health" | jq -r -e ".online==true" HEALTHCHECK --interval=60s --timeout=10s --retries=3 CMD if [ -z "$BASE_PATH" ]; then HEALTHPATH="/health"; else HEALTHPATH="/$BASE_PATH/health" ; fi && curl -s "http://localhost:80$HEALTHPATH" | jq -r -e ".online==true"
CMD statping --port $PORT CMD statping --port $PORT