[object Object]

← back to Wallco Ai

deploy-kamatera.sh: probe https://wallco.ai/health (CF) instead of firewall-blocked origin :9905, and fix HTTP 000000 concat bug (drop || echo from -w pipeline)

bb09c26825847fff4818f4500009f9ed71c2e0db · 2026-05-20 12:16:52 -0700 · Steve Abrams

Files touched

Diff

commit bb09c26825847fff4818f4500009f9ed71c2e0db
Author: Steve Abrams <steve@designerwallcoverings.com>
Date:   Wed May 20 12:16:52 2026 -0700

    deploy-kamatera.sh: probe https://wallco.ai/health (CF) instead of firewall-blocked origin :9905, and fix HTTP 000000 concat bug (drop || echo from -w pipeline)
---
 deploy-kamatera.sh | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/deploy-kamatera.sh b/deploy-kamatera.sh
index a62ee84..4ff2053 100755
--- a/deploy-kamatera.sh
+++ b/deploy-kamatera.sh
@@ -10,7 +10,7 @@ LOCAL_DIR="$(cd "$(dirname "$0")" && pwd)"
 SITE="wallco.ai"
 PM2_NAME="wallco-ai"
 PORT=9905
-HEALTH_URL="http://45.61.58.125:${PORT}/health"
+HEALTH_URL="https://${SITE}/health"
 
 echo "=== wallco.ai deploy to Kamatera ==="
 echo "Local:  $LOCAL_DIR"
@@ -74,9 +74,12 @@ ssh "$REMOTE" "pm2 save"
 # 6. Health check (wait up to 20s)
 echo "[5/6] Health check → $HEALTH_URL"
 for i in $(seq 1 10); do
-  STATUS=$(curl -sS -o /dev/null -w "%{http_code}" --max-time 5 "$HEALTH_URL" 2>/dev/null || echo "000")
+  # `-w "%{http_code}"` always prints 3 digits (000 on conn failure). `|| true`
+  # absorbs curl's non-zero exit without appending another "000" (which was
+  # producing "HTTP 000000" before). `-L` follows the CF redirect if any.
+  STATUS=$(curl -sS -L -o /dev/null -w "%{http_code}" --max-time 8 "$HEALTH_URL" 2>/dev/null || true)
   if [ "$STATUS" = "200" ]; then
-    BODY=$(curl -sS "$HEALTH_URL")
+    BODY=$(curl -sS -L --max-time 8 "$HEALTH_URL")
     echo "  OK ($STATUS): $BODY"
     break
   fi

← 5f15c01 hide Ghosting button when MURAL mode (level 0) is selected —  ·  back to Wallco Ai  ·  ui(designs): move chat pop-out to upper-right; strip ALL sli f7a54b8 →