gandora-mcp: bind time-inference as INFERENCE, gate on GANDORA_MCP_TOKEN, wait longer for the domain
ci / test (push) Successful in 48s
sync / sync (push) Successful in 9s

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014mBuCaQSgWwqhtzsmTBQuM
This commit is contained in:
teahubxyzandClaude Opus 5.5 committed 2026-10-22 19:26:45 +00:00
1 parent 59f3959b22
commit 0ba86c64a8
1 file changed
+8 -9
+8 -9
View File
@@ -23,17 +23,21 @@ jobs:
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID || 'dac3b11890319628eb5cd761445b63ee' }}
SRC_REF: ${{ inputs.ref || 'dev' }}
GANDORA_MCP_TOKEN: ${{ secrets.GANDORA_MCP_TOKEN }}
run: |
set -eu
[ -n "$CLOUDFLARE_API_TOKEN" ] || { echo "::error::CLOUDFLARE_API_TOKEN missing"; exit 1; }
[ -n "$GANDORA_MCP_TOKEN" ] || { echo "::error::GANDORA_MCP_TOKEN missing: the endpoint can spend render quota, so it is not deployed open"; exit 1; }
curl -fsSL "https://teahub.xyz/gandora/site/raw/branch/${SRC_REF}/mcp/worker.js" -o /tmp/worker.js
wc -c /tmp/worker.js
cd .github/time
python3 - <<'PY'
import json, cloudflare as c
import json, os, cloudflare as c
from pathlib import Path
name = "gandora-mcp"
meta = {"main_module": "worker.js", "compatibility_date": c.COMPAT, "bindings": []}
meta = {"main_module": "worker.js", "compatibility_date": c.COMPAT, "bindings": [
{"type": "service", "name": "INFERENCE", "service": "time-inference", "environment": "production"},
{"type": "secret_text", "name": "TOKEN", "text": os.environ["GANDORA_MCP_TOKEN"]}]}
data, ctype = c.multipart([("metadata", "application/json", json.dumps(meta).encode()),
("worker.js", "application/javascript+module", Path("/tmp/worker.js").read_bytes())])
c.cf("PUT", f"{c.account()}/workers/scripts/{name}", data=data, ctype=ctype)
@@ -42,13 +46,8 @@ jobs:
PY
- name: check
run: |
for i in 1 2 3 4 5 6 7 8; do
if curl -fsS https://gandora-mcp.yolopreneur.lol/health; then
echo
curl -fsS -X POST https://gandora-mcp.yolopreneur.lol/mcp -H 'content-type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' | head -c 600; echo
exit 0
fi
for i in $(seq 1 24); do
if curl -fsS https://gandora-mcp.yolopreneur.lol/health; then echo; exit 0; fi
sleep 10
done
echo "::error::gandora-mcp did not answer /health"; exit 1