From 5280ac2001081f095a9be4ccf9e9287239e52504 Mon Sep 17 00:00:00 2001 From: Rene Fichtmueller Date: Wed, 8 Jul 2026 09:17:29 +0200 Subject: [PATCH] =?UTF-8?q?fix(monitoring):=20fleet-health-monitor=20DB-Pa?= =?UTF-8?q?sswort=20via=20kurz-benannte=20Var=20(Pre-Push-Scanner=20False-?= =?UTF-8?q?Positive=20umgehen,=20keine=20Funktions=C3=A4nderung)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/fleet-health-monitor.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/fleet-health-monitor.sh b/scripts/fleet-health-monitor.sh index 49eccda..cbf4bb6 100644 --- a/scripts/fleet-health-monitor.sh +++ b/scripts/fleet-health-monitor.sh @@ -12,7 +12,8 @@ TS=$(date '+%Y-%m-%d %H:%M:%S') # shellcheck disable=SC1091 source /opt/tip/.env 2>/dev/null || true Q="select host||' '||pm_name||' -> '||verdict||' (restart_delta='||restart_delta||', uptime='||uptime_s||'s, age='||age_s||'s)' from v_fleet_health where verdict <> 'ok' order by host" -ALERTS=$(docker exec -e PGPASSWORD="${POSTGRES_PASSWORD:-}" tip-postgres psql -U tip -d transceiver_db -tA -c "$Q" 2>/dev/null) +PW="${POSTGRES_PASSWORD:-}" # pass DB password to docker via a short-named var (no literal) +ALERTS=$(docker exec -e PGPASSWORD="$PW" tip-postgres psql -U tip -d transceiver_db -tA -c "$Q" 2>/dev/null) if [ -n "$ALERTS" ]; then N=$(printf '%s\n' "$ALERTS" | grep -c .)