ops: restore canary_all and harden monitor summary script invocation
This commit is contained in:
17
ops/canary_all.sh
Executable file
17
ops/canary_all.sh
Executable file
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
||||
|
||||
run() {
|
||||
local name="$1"
|
||||
local script="$2"
|
||||
echo "[INFO] === ${name} ==="
|
||||
bash "$script"
|
||||
echo "[OK] === ${name} ==="
|
||||
}
|
||||
|
||||
run "gateway_delivery_priority" "$ROOT/ops/canary_gateway_delivery_priority.sh"
|
||||
run "router_contract" "$ROOT/ops/canary_router_contract.sh"
|
||||
|
||||
echo "[OK] all canaries passed"
|
||||
@@ -10,7 +10,7 @@ TS_START="$(date -u +%Y-%m-%dT%H:%M:%SZ)"
|
||||
mkdir -p "$STATUS_DIR"
|
||||
|
||||
set +e
|
||||
out="$(cd "$ROOT" && ./ops/canary_all.sh 2>&1)"
|
||||
out="$(cd "$ROOT" && bash ./ops/canary_all.sh 2>&1)"
|
||||
rc=$?
|
||||
set -e
|
||||
|
||||
@@ -38,7 +38,7 @@ PY
|
||||
|
||||
# Optional notify to SOFIIA (non-fatal for canary status)
|
||||
set +e
|
||||
notify_out="$("$ROOT/ops/monitor_notify_sofiia.sh" "$STATUS_JSON" 2>&1)"
|
||||
notify_out="$(bash "$ROOT/ops/monitor_notify_sofiia.sh" "$STATUS_JSON" 2>&1)"
|
||||
notify_rc=$?
|
||||
set -e
|
||||
printf '%s\n' "$notify_out" >> "$STATUS_LOG"
|
||||
|
||||
Reference in New Issue
Block a user