Hey tech adventurers! ๐ Ready to turn the mundane world of browser automation into something that would make science fiction jealous? Let's dive into Clickjitsu - a project that proves sometimes the best ideas come from the most questionable engineering decisions! ๐
The Abstract Vision ๐ฎ
Challenge ๐ค: You need to automate web tasks, but traditional browser automation is about as secure as leaving your front door open with a "Free Stuff Inside" sign.
Solution ๐ก: Spawn completely fresh, isolated browser environments in Kubernetes, hand control to AI agents, and watch the digital magic unfold with military-grade security.
Why You'll Love This:
- Watch AI work in real-time via WebRTC streaming ๐บ
- Zero security contamination between sessions ๐ก๏ธ
- Scalable cloud-native architecture that handles enterprise workloads ๐
- Fresh browser instances for every single task ๐งน
Imagine saying "go buy me those fancy headphones" and watching a completely isolated browser environment materialize in the cloud, execute your mission, and vanish without a trace. That's Clickjitsu โ where browser automation meets paranoid-level security! ๐ต๏ธโโ๏ธ
The Security-First Philosophy ๐ก๏ธ
Here's where things get seriously smart: Every single session creates a brand new browser instance from scratch. No cookies, no history, no digital fingerprints from previous adventures. It's like having a perfectly clean rental car for every trip, except the car also self-destructs when you're done! ๐๐ฅ
Why This Security Model Is Genius:
- Zero Cross-Contamination: Your Amazon shopping spree can't accidentally leak into your banking session ๐ฆ
- Fresh Identity Every Time: Each AI agent starts with a completely blank slate ๐งน
- Isolated Kubernetes Namespaces: Every browser session lives in its own fortress ๐ฐ
- Ephemeral by Design: When the task ends, everything vanishes like it never existed ๐จ
- Observable Operations: Real-time streaming means you can supervise your AI minions ๐๏ธ
The Technical Magic Behind the Curtain ๐ญ
Architecture That Actually Makes Sense ๐๏ธ
Fresh Browser Request โ Isolated K8s Namespace โ Virgin Browser + AI Agent
โ
Live Stream โ WebRTC โ Secure Monitoring
โ
Results + Cleanup + Self-Destruct
Each session is like hiring a digital temp worker who:
- Gets a completely clean computer ๐ป
- Follows your exact instructions ๐
- Reports back with results ๐
- Shreds everything when done ๐๏ธ
The Tech Stack That Makes It Possible โจ
- ๐ฌ browser-use: The AI agent doing all the clicking wizardry
- ๐บ neko: Streams the browser chaos via WebRTC so you can watch the show
- โธ๏ธ Kubernetes: Because why make things simple when you can make them distributed and bulletproof?
- ๐น Go: The glue holding this beautiful controlled chaos together
- ๐ง OpenAI: Powers the AI that (hopefully) won't accidentally order 500 rubber ducks
- ๐๏ธ Redis: Session state management that doesn't judge your automation choices
Code That Makes You Go "Wow" โ๏ธ
The session manager is where the real magic happens. Check out this beautiful orchestration:
func (m *Manager) CreateSession(ctx context.Context, req *models.CreateSessionRequest) (*models.Session, error) {
sessionID := uuid.New().String()
namespace := fmt.Sprintf("browser-session-%s", sessionID)
session := &models.Session{
ID: sessionID,
ExternalURL: fmt.Sprintf("https://%s.%s?usr=neko&pwd=neko&embed=1&volume=1",
sessionID, m.config.BrowserDomain),
Status: models.StatusCreating,
Prompt: req.Prompt,
ExpiresAt: time.Now().Add(m.config.BrowserSessionTTL),
}
go m.createSessionResources(context.Background(), session)
return session, nil
}
Each session gets its own Kubernetes namespace โ talk about resource isolation! It's like giving every AI agent their own private mansion that gets demolished after the party ๐ฐ
The AI Runner: Where Dreams Meet Reality ๐ค
The Python runner executing inside each pod is delightfully elegant:
agent = Agent(
task=os.environ["PROMPT"],
llm=ChatOpenAI(model="o4-mini", temperature=1.0),
browser_session=browser_session,
)
history = await agent.run()
result = history.final_result()
It's literally: "Hey AI, here's a pristine browser and a task. Go nuts, but do it securely!" ๐ฅ
Real-World Applications (That Actually Matter) ๐
Enterprise Use Cases That'll Impress Your Boss:
- Automated Testing: Fresh browsers for every test run, eliminating flaky tests caused by session contamination ๐งช
- Market Research: Clean environments for competitive analysis without revealing your digital fingerprints ๐
- Compliance Checking: Isolated sessions for regulatory verification with complete audit trails โ
- Data Gathering: Secure web scraping without contamination or detection ๐ท๏ธ
- Form Automation: Fill repetitive enterprise forms without data leakage ๐
Personal Use Cases That'll Change Your Life:
- Price Monitoring: AI checks deals without accumulating tracking cookies ๐ฐ
- Research Tasks: Clean browsing for sensitive investigations ๐ฌ
- E-commerce Automation: Let AI handle your shopping without compromising your privacy ๐
- Social Media Management: Automate posts and interactions with complete isolation ๐ฑ
The "What Could Go Right" Scenarios ๐ฏ
Unlike traditional browser automation that accumulates digital baggage like a hoarder's basement, Clickjitsu's ephemeral approach means:
- No Session Hijacking: Fresh browser = fresh start every time ๐
- No Data Persistence: Sensitive info never lingers around like a bad smell ๐ซ
- No Cross-Task Interference: Yesterday's shopping can't affect today's banking ๐ชโก๏ธ๐ฆ
- Perfect Audit Trail: Every session is logged, isolated, and traceable ๐
- Scalable Security: Want 100 AI agents? Just scale the pods without security concerns! ๐
Security Wins That Actually Matter ๐
Container-Level Fort Knox ๐ฐ
- Network Segmentation: Kubernetes networking keeps sessions separated like VIP sections at a concert ๐ธ๏ธ
- Resource Limits: AI can't consume infinite resources or accidentally bankrupt you ๐ธ
- Clean Slate Guarantee: Every session starts with zero previous context, like digital amnesia ๐งผ
- Real-Time Monitoring: Watch exactly what your AI agent is doing, no surprises! ๐๏ธ
Taking Security to Ludicrous Speed ๐
For Production Environments, you could take this paranoia to the next level with some seriously hardcore isolation:
- gVisor: Run containers in a user-space kernel for that extra "nope, you're not touching my host OS" feeling ๐ก๏ธ
- Kata Containers: Each container gets its own lightweight VM because why trust anything? ๐ฐ
- Firecracker MicroVMs: AWS-style microVMs that boot faster than your morning coffee โ
# Because regular containers are for peasants
kubectl apply -f - <<EOF
apiVersion: v1
kind: Pod
spec:
runtimeClassName: kata-containers # Or gvisor, or firecracker
containers:
- name: paranoid-browser
image: clickjitsu/browser:latest
EOF
Why Go Full Paranoid? ๐ต๏ธโโ๏ธ
- Kernel-Level Isolation: AI agent escapes? Still trapped in VM-land!
- Hardware-Assisted Security: CPU features working overtime to keep you safe
- Compliance Gold Star: Auditors will weep tears of joy at your isolation levels โญ
- Sleep Better at Night: Because knowing your AI can't accidentally root your cluster is priceless ๐ด
Infrastructure Patterns That Impress ๐ฏ
# Each session gets its own isolated environment
apiVersion: v1
kind: Namespace
metadata:
name: browser-session-uuid-here
---
# Browser container with Chrome DevTools + MicroVM isolation
# AI runner container with browser-use + gVisor sandboxing
# All ephemeral, all secure, all magnificently over-engineered
The Infrastructure Wins That Matter ๐
Despite being born from "questionable life choices," Clickjitsu showcases serious cloud-native patterns:
- Ephemeral Workloads: Each session is completely isolated and self-cleaning ๐งน
- Horizontal Scalability: Want 100 AI shoppers? Just scale the pods! ๐
- Resource Management: Proper CPU/memory limits prevent AI shopping sprees from breaking your cluster ๐ณ
- WebRTC Streaming: Real-time browser viewing because watching AI click buttons is surprisingly addictive ๐๏ธ
- GitOps Ready: Infrastructure as code that would make your DevOps team weep with joy ๐ญ
Warning Labels and Disclaimers โ ๏ธ
This is a one-day hack that turned into something surprisingly robust โ use responsibly! Side effects may include:
- Mysterious charges on your credit card (set those spending limits!) ๐ณ
- AI developing sentience and judging your browsing habits ๐จโโ๏ธ
- Kubernetes bills that make you question life choices ๐ธ
- Your browser automation having better security than most enterprise systems ๐ข
- Colleagues asking "how the hell did you build that?" ๐คฏ
The Future of Secure Automation ๐ฎ
This isn't just about letting AI click buttons โ it's about creating a paradigm where automation meets paranoid-level security. Imagine:
- Corporate AI Assistants: Safely handling sensitive business processes without data leakage ๐ผ
- Personal Digital Butlers: Managing your online life without privacy nightmares ๐
- Research Automation: Gathering competitive intelligence without leaving digital footprints ๐ต๏ธ
- Compliance Automation: Meeting regulations with verifiable isolation and audit trails โ
- Zero-Trust Browsing: Every web interaction happens in a disposable, monitored environment ๐๏ธ
Try It Yourself (If You Dare) ๐ฎ
Want to watch AI navigate the web while you sip coffee in your security-hardened ivory tower? The project is open source and ready for your own questionable experiments!
Getting Started:
# Clone the madness
git clone https://github.com/pmdroid/clickjitsu
# Deploy to your K8s cluster
# Watch AI do your bidding
# Profit (securely)
Just remember: with great AI power comes great responsibility (and the need for really good monitoring) ๐ท๏ธ
Key Takeaways That'll Stick ๐ฏ
- Security Through Isolation: Fresh environments eliminate contamination risks better than hand sanitizer ๐ก๏ธ
- Observable AI: Real-time streaming lets you supervise your digital minions like a benevolent overlord ๐
- Scalable Architecture: Cloud-native design handles enterprise workloads without breaking a sweat ๐
- Zero Persistence: What happens in the container, stays in the container (and then gets obliterated) ๐
- Infrastructure as Entertainment: Who knew watching AI browse the web could be this addictive? ๐ฟ
The Bottom Line ๐ฐ
Clickjitsu proves that sometimes the most useful innovations come from solving problems you didn't know you had. It's browser automation for the age of zero-trust architecture, where every click is monitored, every session is isolated, and every result is achieved without compromising your digital soul.
Ready to delegate your browser tasks to AI agents while keeping everything locked down tighter than Fort Knox? Your secure automation journey starts here! ๐
Built with โค๏ธ and questionable engineering decisions that somehow resulted in enterprise-grade security. Because in 2025, even our browser automation needs better security than most banks ๐ ๐ฆ
P.S. - Yes, it actually works. No, we can't be held responsible for what your AI decides to buy. Please set spending limits. I'm not kidding about this one! ๐ธ
Top comments (0)