fix: harden Nexus runtime health and rollback
This commit is contained in:
@@ -60,7 +60,7 @@ JWT_KEY=${ENV_JWT_KEY}
|
||||
JWT_ISSUER=nexus
|
||||
JWT_AUDIENCE=nexus-web
|
||||
BOOTSTRAP_OWNER_EMAIL=vmbao62@hotmail.de
|
||||
OPENCLAW_BASE_URL=http://host.docker.internal:18789
|
||||
OPENCLAW_BASE_URL=http://openclaw-gateway-bao:18789
|
||||
OPENCLAW_GATEWAY_TOKEN=${ENV_OPENCLAW_TOKEN:-}
|
||||
OPENCLAW_GATEWAY_PASSWORD=
|
||||
NEXUS_VERSION=${VERSION}
|
||||
@@ -140,9 +140,15 @@ echo "Checking live health"
|
||||
retry=0
|
||||
while [ "$retry" -lt 6 ]; do
|
||||
retry=$((retry + 1))
|
||||
if curl -fsS --max-time 10 "$BASE_URL/health" >/dev/null; then
|
||||
echo "Health check passed"
|
||||
break
|
||||
health_body="$(curl -fsS --max-time 10 "$BASE_URL/health" 2>/dev/null || true)"
|
||||
case "$health_body" in
|
||||
'{"status":"Healthy"'*)
|
||||
echo "Health check passed"
|
||||
break
|
||||
;;
|
||||
esac
|
||||
if [ -n "$health_body" ]; then
|
||||
echo "Health endpoint is reachable but not healthy: $health_body" >&2
|
||||
fi
|
||||
if [ "$retry" -eq 6 ]; then
|
||||
echo "Health check failed" >&2
|
||||
|
||||
Reference in New Issue
Block a user