✅ What's Working: - WebSocket connections established (patched worker to intercept upgrades) - Real-time event streaming: Agent → DO → Browser - Terminal panel showing live command execution - Agent chat panel showing LLM thoughts - Full infrastructure: UI → API → DO → SSH Proxy → LangGraph Agent 🔧 Key Changes: - Created standalone DO worker at workers/bandit-agent-do/ - Deployed DO as separate Worker (bandit-agent-do) - Updated wrangler.jsonc to reference external DO via script_name - Modified patch-worker.js to intercept WS upgrades before Next.js - Added __name polyfill to fix esbuild helper - Created pnpm workspace config for monorepo 📝 Architecture: - Frontend (Next.js) → Cloudflare Worker - Worker intercepts /api/agent/*/ws → forwards to DO - DO (bandit-agent-do) → manages WebSocket connections - DO → calls SSH Proxy API - SSH Proxy → runs LangGraph agent → executes SSH commands - Events stream back: SSH Proxy → DO → WebSocket → UI 🐛 Known Issue: - Agent logic needs refinement (not parsing SSH output correctly) - But core infrastructure is 100% functional! This resolves all WebSocket and real-time streaming issues.
This is a Next.js project bootstrapped with create-next-app.
Getting Started
First, run the development server:
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
Open http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.
This project uses next/font to automatically optimize and load Geist, a new font family for Vercel.
Learn More
To learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!
Deploy on Vercel
The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.
Check out our Next.js deployment documentation for more details.