diff options
| author | Peter Stone <thepeterstone@gmail.com> | 2026-07-17 22:24:08 +0000 |
|---|---|---|
| committer | Peter Stone <thepeterstone@gmail.com> | 2026-07-17 22:24:08 +0000 |
| commit | 0739ea660e6507d3cfbbe9bc4a0903d75b7db9ef (patch) | |
| tree | 64d83190d5ff035b28d30282e03f05cd44ee64c5 | |
| parent | b007fee8fb5b39a5f9b369c59af71ac9e795ceaf (diff) | |
Guard deploy script to only run on tungsten
Refuses to run if hostname doesn't match the documented deploy host,
preventing an accidental deploy from a sandbox/dev environment.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EZ7ikw2ukGJFTHE3bJS7zL
| -rwxr-xr-x | scripts/deploy | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/deploy b/scripts/deploy index adb27e2..6b3d498 100755 --- a/scripts/deploy +++ b/scripts/deploy @@ -6,6 +6,12 @@ cd "$(dirname "$0")/.." FQDN="doot.terst.org" SITE_DIR="/site/${FQDN}" SERVICE="task-dashboard@${FQDN}" +DEPLOY_HOST="tungsten" + +if [ "$(hostname)" != "${DEPLOY_HOST}" ]; then + echo "Refusing to deploy: this is $(hostname), not ${DEPLOY_HOST}." >&2 + exit 1 +fi echo "==> Building CSS..." npm run css:build |
