[object Object]

← back to Coming Soon Template

add Worker deploy script for the 2 Pages-cap casualties

e51fd58712f75b6a9c24b1f0f9fa1390af6ff4c7 · 2026-05-18 12:47:17 -0700 · SteveStudio2

Files touched

Diff

commit e51fd58712f75b6a9c24b1f0f9fa1390af6ff4c7
Author: SteveStudio2 <stevestudio2@SteveStacStudio.lan>
Date:   Mon May 18 12:47:17 2026 -0700

    add Worker deploy script for the 2 Pages-cap casualties
---
 scripts/deploy_workers.sh      | 37 +++++++++++++++++++++++++++++++++++++
 workers/bhbutler/wrangler.toml |  5 +++++
 2 files changed, 42 insertions(+)

diff --git a/scripts/deploy_workers.sh b/scripts/deploy_workers.sh
new file mode 100755
index 0000000..ba44f7c
--- /dev/null
+++ b/scripts/deploy_workers.sh
@@ -0,0 +1,37 @@
+#!/usr/bin/env bash
+# Deploy the project-cap-casualty domains as static-asset Cloudflare Workers.
+# Pages is capped at 20 projects/account; Workers are not. These two domains
+# (bhbutler.com, boulevardbutler.com) get their coming-soon page served by a
+# tiny assets-only Worker instead of a Pages project.
+#
+#   ./scripts/deploy_workers.sh
+#
+# Idempotent: re-deploying just publishes a new version.
+set -euo pipefail
+cd "$(dirname "$0")/.."
+
+[ -f .env ] || { echo "✗ missing .env"; exit 1; }
+set -a; source .env; set +a
+export CLOUDFLARE_API_TOKEN="${CLOUDFLARE_PAGES_TOKEN:?CLOUDFLARE_PAGES_TOKEN not set}"
+
+DOMAINS=(bhbutler.com boulevardbutler.com)
+
+for domain in "${DOMAINS[@]}"; do
+  project="${domain%.com}"
+  [ -f "out/$domain/index.html" ] || { echo "✗ no artifact: out/$domain"; exit 1; }
+  workdir="workers/$project"
+  mkdir -p "$workdir"
+  cat > "$workdir/wrangler.toml" <<EOF
+name = "$project"
+compatibility_date = "2026-05-18"
+
+[assets]
+directory = "../../out/$domain"
+EOF
+  echo "→ deploying Worker: $project  (assets: out/$domain)"
+  ( cd "$workdir" && npx --yes wrangler deploy )
+  echo
+  sleep 6
+done
+
+echo "✓ worker deploys done"
diff --git a/workers/bhbutler/wrangler.toml b/workers/bhbutler/wrangler.toml
new file mode 100644
index 0000000..ea6c5f2
--- /dev/null
+++ b/workers/bhbutler/wrangler.toml
@@ -0,0 +1,5 @@
+name = "bhbutler"
+compatibility_date = "2026-05-18"
+
+[assets]
+directory = "../../out/bhbutler.com"

← c4cad7b GoDaddy NS-flip via API (replaces fragile Playwright scraper  ·  back to Coming Soon Template  ·  deploy bhbutler+boulevardbutler as Workers; flip-script guar a06f760 →