Master AI Fleet Architecture & Operations Runbook
T3 Code • CLIProxyAPI v8 • Antigravity (agy) • DGX Spark • Tony WSL • Tailscale Isolation • Multi-Account Artifact Hosting
1. How It All Fits Together
- T3 Code (the cockpit): Lets you control coding agents, git worktrees, and repos on any machine from your MacBook or iPhone — without screen-sharing or leaving messy terminal windows open.
- CLIProxyAPI (the fuel switchboard): Sits locally on each machine and routes requests to Google, Claude, OpenRouter, or your local DGX Spark GPU. Everyone uses their own AI accounts — Tony never touches your Google Ultra or Claude pool, and corporate work never mixes with personal work.
cpa-open(the master keyring): One command on your MacBook opens any of the 4 switchboard dashboards and puts the right password on your clipboard from macOS Keychain.
- Strict Tenant & Identity Isolation: Two separate Tailscale tailnets —
atccorp.com(corporate:MGMT01,spark-6122) andraebconsulting.com(personal/consulting:maurices-macbook-pro,swoop-server) — plus Tony's separate personal tailnet node (tony.tailf9ffa9.ts.net) shared via Tailscale node sharing. - Loopback-First Exposure: Every T3 Code server (
127.0.0.1:3773) and CLIProxyAPI proxy (127.0.0.1:8317) binds strictly to loopback. Remote access is terminated exclusively bytailscale serve(private tailnet HTTPS with automatic Let's Encrypt certs;tailscale funnelis never used). - Hard-Locked Managed Policy: Machine-wide T3 Code Managed Policy files (
C:\Program Files\T3Code\policy.jsonon MGMT01,/etc/t3code/policy.jsonon Tony WSL) enforceconnect: false,telemetry: false, andpreviewTunnel: false. - Zero-Secret Repo & Backup Posture: All Management Keys, Client API Keys, and DB credentials live in macOS Keychain (
account: cliproxyapi/mcp-toolbox) orchmod 600local host files. CLIProxyAPI v8 bcrypt-hashessecret-keyin place on startup.
2. Fleet Architecture & Traffic Flow Diagram
3. Node & Service Inventory
MacBook Pro Control Plane
Tailscale: maurices-macbook-pro.tailf9ffa9.ts.net (100.120.81.108, raebconsulting.com)
Versions: T3 Code v0.1.13, CLIProxyAPI v8.0.79 (Homebrew), agy 1.5.17, mcp-toolbox v1.18.0
Services: brew services (cliproxyapi on 127.0.0.1:8317), Tailscale Serve :8317 & :8443
Guardrails: No-Receipt-No-Merge hooks (~/.gemini/config/hooks.json), ops-backup, verify-ai-stack
MGMT01 atccorp.com
Tailscale: mgmt01.tail222e7.ts.net (100.113.254.114, shared to Maurice :8443, :22)
Services: Scheduled Task T3Code-MGMT01 (AtStartup, PT0S, 3x restart), Tailscale Serve :8443
Policy: C:\Program Files\T3Code\policy.json (connect/telemetry/previewTunnel: false)
Pending Fix: Run gh auth login --web --insecure-storage in RDP to replace Fine-Grained PAT for PR status checks.
DGX Spark (spark-6122) Dual Hub + GPU
Tailscale: spark-6122.tail222e7.ts.net (100.70.90.19, atccorp.com, shared to Maurice :8318, :22)
Work Hub (:8317): Strictly atccorp.com; managed from MacBook via cpa-open spark-work SSH tunnel (:8327).
Personal Hub (:8318): HTTPS Tailscale Serve; serves local qwen3.8-flash-next GPU model.
Planned: Private ATC static artifact server on atccorp.com Tailscale (:8444).
Tony PC + WSL Ubuntu Independent
Tailscale: tony.tailf9ffa9.ts.net (100.110.49.81, SSH alias tony-win)
Versions: T3 Code v0.1.13 (~/.local/share/t3), CLIProxyAPI v8.1.9, agy 1.5.20 (tony.faststop.la@)
Services: systemd --user (cliproxyapi.service, t3-serve.service), Windows Tailscale Serve :8443 & :8317
Policy: /etc/t3code/policy.json (organization: "Tony-Swoop", connect/telemetry/previewTunnel: false)
4. CLIProxyAPI Hubs & cpa-open Launcher
cpa-open <name> in Terminal. It opens the right HTTPS dashboard in your browser and copies the matching password to your clipboard — just press Cmd+V to log in.
| Command | Dashboard URL | Keychain Service (-a cliproxyapi) |
Verified |
|---|---|---|---|
cpa-open mac |
https://maurices-macbook-pro.tailf9ffa9.ts.net:8317/management.html |
CLIProxyAPI Management Key |
HTTP 200 |
cpa-open spark-personal |
https://spark-6122.tail222e7.ts.net:8318/management.html |
Spark Personal Management Key |
HTTP 200 |
cpa-open spark-work |
http://127.0.0.1:8327/management.html (SSH tunnel → spark:8317) |
Spark Work Management Key |
tunnel:200 |
cpa-open tony |
https://tony.tailf9ffa9.ts.net:8317/management.html |
Tony CLIProxyAPI Management Key |
HTTP 200 |
# Check status of all 4 hubs cpa-open list # Open dashboard + copy Management Key to clipboard cpa-open tony # Copy Client API Key only (for T3 Code Settings -> CLIProxy Hub) cpa-open tony --client-key # Close any active SSH tunnels (spark-work) cpa-open close
5. Tailscale Isolation, Sharing & ACL Rules
atccorp.com) and your consulting/personal network (raebconsulting.com) stay completely separate. You share only specific ports from MGMT01 and DGX Spark to your own account so you can work seamlessly from your MacBook without ever exposing corporate servers to Tony.
| Host | Native Tailnet | Shared To | Allowed Ports | Notes |
|---|---|---|---|---|
mgmt01 |
atccorp.com |
david@raebconsulting.com |
8443, 22 |
T3 Code + SSH only. Never share to Tony. |
spark-6122 |
atccorp.com |
david@raebconsulting.com |
8318, 22 |
Personal Hub + SSH. Work Hub :8317 stays internal to atccorp.com. |
tony |
Tony's tailnet | david@raebconsulting.com |
8443, 8317, 22 |
T3 Code + CLIProxyAPI + SSH. Zero access back to atccorp.com. |
atccorp.com ACL): Narrow src: ["autogroup:shared"] to ["david@raebconsulting.com"] in the atccorp.com Tailscale ACL before ever inviting another user into raebconsulting.com.
6. Zero-Secret Posture & Managed Policy Locks
macOS Keychain Map (-a cliproxyapi)
CLIProxyAPI Management Key/Client API KeySpark Personal Management Key/Client API KeySpark Work Management Key/Client API KeyTony CLIProxyAPI Management Key/Client API Key- Planned:
Cloudflare Swoop API Token&Cloudflare ATC API Token
T3 Code Managed Policy Schema (v0.1.11+)
Strict schema (onExcessProperty: "error"). Deployed at C:\Program Files\T3Code\policy.json (MGMT01) and /etc/t3code/policy.json (Tony WSL):
{
"schemaVersion": 1,
"organization": "Tony-Swoop",
"limits": {
"connect": false,
"telemetry": false,
"previewTunnel": false
}
}
7. Tony's Box & 3-Layer WSL Keepalive
wsl-keepalive + .wslconfig) that keeps Ubuntu running 24/7 after reboots. Always keep that layer ON — it's what keeps Tony's T3 Code and CLIProxyAPI alive. The only optional piece is the old tmux Claude service (swoop-claude.service), which you can disable once you're driving all Swoop work from T3 Code.
tony-win- Layer 1 — Keep ON: Windows Scheduled Task
wsl-keepalive(runswsl.exe -d Ubuntu --exec sleep infinityat logon + every 5m),C:\Users\Tony\.wslconfig(vmIdleTimeout=-1, 8 GB RAM, 12 cores),/etc/wsl.conf(systemd=true), andloginctl enable-linger tony. - Layer 2 — Active T3 Stack (Keep ON):
cliproxyapi.service(127.0.0.1:8317) andt3-serve.service(127.0.0.1:3773,--base-dir /home/tony/.t3), exposed via Windows Tailscale Serve on:8317and:8443. - Layer 3 — Legacy tmux Claude (Optional):
swoop-claude.servicerunsgit pull --ff-onlyandclaude --rc --continuein tmuxswoop. Disable it once migrated to T3 Code so two agents don't editswoop-warehousemainsimultaneously and to save RAM inside the 8 GB WSL cap.
# Mint a fresh 15-minute T3 pairing code for Tony's box ssh -T tony-win "wsl -d Ubuntu -- /home/tony/.local/bin/t3 pair --base-dir /home/tony/.t3 --ttl 15m --label MacBook" # Disable legacy swoop-claude.service (keeps wsl-keepalive, t3-serve, cliproxyapi ON) ssh -T tony-win "wsl -d Ubuntu -- systemctl --user disable --now swoop-claude.service" # Re-enable swoop-claude.service if ever needed ssh -T tony-win "wsl -d Ubuntu -- systemctl --user enable --now swoop-claude.service"
8. AI-Agnostic HTML Artifact Hosting Architecture
publish-artifact). Links never expire when you switch AI accounts, and corporate ATC work stays 100% separated from Swoop/RAEB work.
- Zero Cross-Account Bleed:
publish-artifactnever uses a single globalwrangler login. Instead, it injectsCLOUDFLARE_API_TOKENandCLOUDFLARE_ACCOUNT_IDper invocation from macOS Keychain (Cloudflare Swoop API TokenvsCloudflare ATC API Token). - Zero-Trust Access (Free up to 50 users): Cloudflare Zero Trust Access sits in front of both Pages projects so links require a 1-click email OTP or Google sign-in — no Claude account needed, works from iPhone or corporate laptops.
- Strict Internal Option for ATC:
--profile atc-privatecopies HTML over SSH tospark-6122and serves it viatailscale serve --https=8444(auto-indexed, reachable only insideatccorp.com).
9. Daily & Recovery Operations Playbook
# 1. Run full 8-point local AI stack health check verify-ai-stack # 2. Check all 4 CLIProxyAPI hubs & open any dashboard cpa-open list cpa-open mac | spark-personal | spark-work | tony # 3. Mirror local scripts, LaunchAgents, hooks & redacted configs to ~/ops/mac/ ops-backup # 4. Inspect Tony's WSL services & Tailscale Serve status ssh -T tony-win "wsl -d Ubuntu -- systemctl --user status cliproxyapi.service t3-serve.service --no-pager && tailscale serve status" # 5. If Tony's PC rebooted and nobody logged into Windows yet ssh tony-win "schtasks /run /tn wsl-keepalive"
10. Continuous Change Log
| Date | Scope | Change Summary |
|---|---|---|
2026-11-30 |
Fleet / Runbook | Rebuilt Master Runbook with Plain/Tech mode toggle, SVG topology + multi-account artifact hosting diagrams; added Swoop (CF Pages) + ATC Hybrid (separate ATC CF account + Spark Tailscale) architecture. |
2026-11-30 |
CLIProxyAPI / Mac & Tony | Enabled tailnet-only HTTPS Tailscale Serve (:8317) on MacBook Pro and Tony's box; created cpa-open launcher with 8 verified Keychain keys; reset Tony's bcrypt-hashed management key and verified HTTP 200 auth. |
2026-11-30 |
Tony WSL | Installed independent CLIProxyAPI v8.1.9 + T3 Code v0.1.13 under systemd --user, hard-locked /etc/t3code/policy.json, exposed T3 on https://tony.tailf9ffa9.ts.net:8443, paired Maurice's T3 Desktop. |
2026-11-28 |
Tailscale / MacBook | Configured atccorp.com → raebconsulting.com node sharing for MGMT01 (:8443, :22) and spark-6122 (:8318, :22); fixed Work Laptop corporate NRPT DNS with static hosts pins. |
2026-11-27 |
MacBook Guardrails | Built No-Receipt-No-Merge hooks (agy-receipt, 10/10 tests), installed googleapis/mcp-toolbox v1.18.0 + mcp-db read-only SQL wrapper, hardened MGMT01 Managed Policy & T3Code-MGMT01 task. |
2026-11-25 |
Baseline | Initial T3Code_CLIProxy_Runbook.html covering MacBook Pro, MGMT01, and DGX Spark Dual-Hub baseline. |