From 32e30f7e8b08e81993f29e359987f37e66d579f7 Mon Sep 17 00:00:00 2001 From: admin Date: Wed, 26 Aug 2026 22:31:12 -0700 Subject: [PATCH] Add: call git-guard.sh at top of stack-deploy.sh to enforce sync before deploy --- deploy/stack-deploy.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/deploy/stack-deploy.sh b/deploy/stack-deploy.sh index 4eea86d..3879d79 100755 --- a/deploy/stack-deploy.sh +++ b/deploy/stack-deploy.sh @@ -28,6 +28,10 @@ DIR="/volume1/docker/compose-files" PY="$DIR/deploy/envparse.py" GLOBAL_ENV="$DIR/deploy/global.env" +# ── Pre-flight: ensure local checkout is in sync with Gitea ───────────────── +# Prevents deploying from a stale/diverged local tree (see incident 2026-08-26). +"$DIR/deploy/git-guard.sh" || { echo "ERROR: git-guard check failed. Deploy aborted."; exit 1; } + # ── Locate compose file(s) ────────────────────────────────────────────────── FOLDER="$DIR/$STACK"