style(no-slop): remove every em-dash + banned words across all modules + capstone
Apply the no-ai-slop standard (now binding in AGENTS.md): the em-dash character is banned outright (restructured, not blind-replaced), plus the banned word/phrase list (delve, leverage, robust, seamless, truly, unlock, etc.). 0 em-dashes remain in modules + capstone; the only "robust" left is the planted M10 ai-change.patch trap. Module H1 titles use a colon separator. All deliberate teaching devices preserved; labs compile/parse (py/sh/yaml/json); no junk. AGENTS.md updated with the hard no-slop rules. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TfzV5QvtPDz8LJS3Pu5VLT
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# deploy.sh — the deploy step of CD, simulated with a local container run.
|
||||
# deploy.sh: the deploy step of CD, simulated with a local container run.
|
||||
#
|
||||
# The five steps of any deploy, provider-neutral (see the module README):
|
||||
# 1. build/pull the specific image tag 4. health-check before trusting it
|
||||
@@ -37,7 +37,7 @@ fi
|
||||
|
||||
# --- Steps 2 + 3: start the new version with runtime config/secrets injected (Module 17) ----------
|
||||
# Note: APP_VERSION is config supplied at run time, NOT baked into the image. A real deploy would
|
||||
# also pass secrets here (e.g. --env-file, a mounted secret, or a secrets-manager lookup) — never
|
||||
# also pass secrets here (e.g. --env-file, a mounted secret, or a secrets-manager lookup), never
|
||||
# committed, never in the image.
|
||||
start_version() {
|
||||
local tag="$1"
|
||||
@@ -67,13 +67,13 @@ say "Health-checking http://localhost:${PORT}/health"
|
||||
if healthy; then
|
||||
# --- Step 5a: cut over. Record this as the new known-good for the next deploy's rollback target.
|
||||
echo "${TAG}" > "${STATE_FILE}"
|
||||
say "DEPLOY OK — ${IMAGE}:${TAG} is live and healthy"
|
||||
say "DEPLOY OK: ${IMAGE}:${TAG} is live and healthy"
|
||||
curl -s "http://localhost:${PORT}/health"; echo
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# --- Step 5b: ROLLBACK. The new version failed its health check. ----------------------------------
|
||||
say "HEALTH CHECK FAILED for ${IMAGE}:${TAG} — rolling back"
|
||||
say "HEALTH CHECK FAILED for ${IMAGE}:${TAG}, rolling back"
|
||||
docker rm -f "${CONTAINER}" >/dev/null 2>&1 || true
|
||||
|
||||
if [ -z "${PREVIOUS}" ]; then
|
||||
@@ -86,10 +86,10 @@ fi
|
||||
say "Restoring previous good version ${IMAGE}:${PREVIOUS}"
|
||||
BREAK="" start_version "${PREVIOUS}" # clear BREAK so the good version comes up clean
|
||||
if healthy; then
|
||||
say "ROLLED BACK — ${IMAGE}:${PREVIOUS} is live and healthy. The bad deploy reverted itself."
|
||||
say "ROLLED BACK: ${IMAGE}:${PREVIOUS} is live and healthy. The bad deploy reverted itself."
|
||||
curl -s "http://localhost:${PORT}/health"; echo
|
||||
exit 1 # exit non-zero: the deploy you asked for did NOT ship, even though service recovered
|
||||
else
|
||||
echo "Rollback FAILED — service is DOWN. Investigate ${IMAGE}:${PREVIOUS}." >&2
|
||||
echo "Rollback FAILED: service is DOWN. Investigate ${IMAGE}:${PREVIOUS}." >&2
|
||||
exit 2
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user