mirror of
https://github.com/0rangebananaspy/authelia.git
synced 2024-09-14 22:47:21 +07:00
22 lines
576 B
Bash
Executable File
22 lines
576 B
Bash
Executable File
#!/bin/sh
|
|
|
|
source /app/.healthcheck.env
|
|
|
|
if [ -z "${X_AUTHELIA_HEALTHCHECK}" ]; then
|
|
exit 0
|
|
fi
|
|
|
|
if [ -z "${X_AUTHELIA_HEALTHCHECK_SCHEME}" ]; then
|
|
X_AUTHELIA_HEALTHCHECK_SCHEME=http
|
|
fi
|
|
|
|
if [ -z "${X_AUTHELIA_HEALTHCHECK_HOST}" ]; then
|
|
X_AUTHELIA_HEALTHCHECK_HOST=localhost
|
|
fi
|
|
|
|
if [ -z "${X_AUTHELIA_HEALTHCHECK_PORT}" ]; then
|
|
X_AUTHELIA_HEALTHCHECK_PORT=9091
|
|
fi
|
|
|
|
wget --quiet --no-check-certificate --tries=1 --spider "${X_AUTHELIA_HEALTHCHECK_SCHEME}://${X_AUTHELIA_HEALTHCHECK_HOST}:${X_AUTHELIA_HEALTHCHECK_PORT}${X_AUTHELIA_HEALTHCHECK_PATH}/api/health" || exit 1
|