Switch deploy tooling to Gitea (no GitHub)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-08-11 03:54:32 +12:00
parent 3d1eacc2a3
commit 0faf4e5f38
3 changed files with 90 additions and 9 deletions

View File

@@ -3,11 +3,32 @@
Static single-file WattHound demo (ABC Electrical) served at
https://watthound-demo.sculpt7.com
Deployed via Coolify (project `watthound-demo`) using the Dockerfile build pack:
nginx:alpine serving `index.html`.
## Hosting (NO GitHub)
## Update the live demo
1. Replace `index.html` with the new build.
2. `git commit -am "update demo" && git push`
3. Redeploy: Coolify auto-deploy on push (if webhook enabled), or trigger the
Coolify deploy for app `watthound-demo`.
- **Git host:** `gitea.sculpt.co.nz/macjones/watthound-demo` (Mac's own self-hosted
Gitea, public repo). GitHub is not involved anywhere.
- **Runtime:** Coolify app `watthound-demo-gitea`
(uuid `hd9qde2w6xrmnippah409jgt`) builds the `Dockerfile`
(nginx:alpine serving `index.html`) straight from Gitea `main`.
## Update the live demo (repeatable, no GitHub)
```
./deploy.sh # commit ./index.html, push to Gitea, redeploy, verify
./deploy.sh /path/to/new/index.html # drop in a new build first, then the above
```
That script: commits `index.html`, `git push gitea main`, triggers the Coolify
deploy via API, then polls the FQDN until it serves the new byte size.
### Manual equivalent
```
git add index.html && git commit -m "update demo"
git push gitea main
# then trigger Coolify (token from myPKA .env, never printed):
BASE="$(grep '^COOLIFY_URL=' /Users/macjones/Projects/watthound/mypka/.env | cut -d= -f2-)/api/v1"
TOKEN="$(grep '^COOLIFY_API_TOKEN=' /Users/macjones/Projects/watthound/mypka/.env | cut -d= -f2-)"
curl -sS -X POST -H "Authorization: Bearer $TOKEN" \
"$BASE/deploy?uuid=hd9qde2w6xrmnippah409jgt&force=true"
```