integration wiring
Integration Wiring Plan (for AI Assistants)
Moved from CLAUDE.md to reduce context size. Consult when working on platform integration tasks.
Most Impactful Next Steps
| Priority | Area | Action | Repos / location |
|---|---|---|---|
| 1 | agent-buildkit → agent-mesh (tokens) | Remove parsing of registry.yaml for GitLab tokens. Call mesh GET /v1/service-accounts/gitlab/:agentType/token. SOD violation; unblocks secure rotation. | agent-buildkit: agent-orchestrator-client, webhook-agent-spawner |
| 2 | agent-buildkit → agent-router (Vast.ai) | Remove Vast.ai deploy/provider logic from buildkit. Route through agent-router: POST /api/v1/vastai/deploy, POST /api/v1/route. | agent-buildkit: services that deploy or route to Vast.ai |
| 3 | Oracle env single source | One canonical env template (/root/.env.local). Include: AGENT_MESH_URL, MCP_URL, GKG_URL, VASTAI_API_KEY, A2A_STREAM_URL, A2A_URL, ORACLE_HOST. Sync to NAS and GitLab CI. | config-templates/ or agent-docker |
| 4 | GitLab runners on Oracle | Register runners on Oracle. Document job template with Oracle runner tag. | gitlab_components |
| 5 | A2A collector on Oracle | Run A2A stack on Oracle (collector:9004, stream:9005). Set A2A_URL and A2A_STREAM_URL. | agent-mesh deployments; agent-docker |
| 6 | agent-router mesh default | Ensure production Oracle deploy sets AGENT_MESH_URL in env. | agent-router: production-gateway-server.ts |
| 7 | platform-agents Duo alignment | Align GitLab Duo agent config with registry.yaml (21 agents). | platform-agents .gitlab/duo/agents/ |
| 8 | Vast.ai ownership | All Vast.ai logic in agent-router. Document whether agent-docker's vastai-* are legacy. | agent-router (owner) |
Wire Everything Up (7 Phases)
Phase 1: One env to rule them all
Create canonical Oracle env template. Required keys: AGENT_MESH_URL, MCP_URL, GKG_URL, A2A_URL, A2A_STREAM_URL, STUDIO_DEPLOY_TOKEN, BUILDKIT_PATH, VASTAI_API_KEY, ORACLE_HOST. Sync to NAS .env.production and GitLab CI.
Phase 2: Buildkit → mesh and router
Remove GitLab token reading from registry.yaml. Remove direct Vast.ai logic. All through mesh/router APIs.
Phase 3: Studio bridge and desktop → platform
Set MESH_URL in Studio bridge env. Set BUILDKIT_PATH and STUDIO_DEPLOY_TOKEN on Oracle. Desktop app points at https://studio.blueflyagents.com.
Phase 4: Mesh discovery and registry live
Deploy agent-mesh with discovery API and Redis TTL. Buildkit agents discover --registry-url <mesh>. OSSA workspace publish uses MESH_URL.
Phase 5: Router and A2A on Oracle
Set AGENT_MESH_URL for router. Run A2A stack on Oracle (9004/9005).
Phase 6: GitLab runners and Duo
Register runners on Oracle. Align Duo agent config with registry.yaml.
Phase 7: End-to-end verification
Verify from Mac (buildkit platform status), Agent Studio desktop (Registry + Platform status), anywhere (POST to studio API), MCP clients, A2A stream.
Who Calls Whom
- Agent Studio → Studio bridge → mesh discovery + buildkit CLI
- Buildkit → mesh (tokens, discovery), agent-router (Vast.ai only), MCP/GKG via env
- OSSA workspace publish → mesh discovery
- Router → mesh (gateway discovery), foundation-bridge/LLM providers
- All public clients → *.blueflyagents.com (tunnel → Oracle)
Manual Steps (must do by hand)
- Hugging Face MCP: Set
HF_TOKENandHF_MCP_URLin Oracle/root/.env.local. SSH:flux423@oracle-platform.tailcf98b3.ts.net. - Ollama on NAS:
docker compose up -dfor NAS unified stack. SetOLLAMA_URL=http://ollama:11434.