Find a file
Sprite 7cf733a351 refactor: Extract ENV_TEMP pattern to inject_env_vars_local (E2B)
Converted 11 E2B scripts to use inject_env_vars_local():
- aider, claude, amazonq, cline, codex
- gemini, goose, gptme, interpreter, nanoclaw, openclaw

Pattern reduces ~10-15 lines to 3-4 lines per script.

Special cases:
- nanoclaw.sh: Has additional DOTENV_TEMP for agent-specific .env file
- gptme.sh: Had manual rm instead of trap, now handled by shared function

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-08 04:06:33 +00:00
.claude Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
.githooks Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
.github/workflows ci: add shellcheck linting infrastructure 2026-02-08 01:08:34 +00:00
aws-lightsail Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
cli refactor: Add trap-based cleanup for temp files in library code 2026-02-08 03:31:47 +00:00
digitalocean Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
docs docs: add Round 6 refactoring summary 2026-02-08 00:55:36 +00:00
e2b refactor: Extract ENV_TEMP pattern to inject_env_vars_local (E2B) 2026-02-08 04:06:33 +00:00
fly Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
gcp Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
hetzner Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
lambda Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
linode Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
modal refactor: Extract ENV_TEMP pattern to inject_env_vars_local (Modal) 2026-02-08 04:04:01 +00:00
shared refactor: Extract ENV_TEMP pattern to inject_env_vars_local (Modal) 2026-02-08 04:04:01 +00:00
sprite Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
test refactor: Add default case to script-specific assertions 2026-02-08 03:56:29 +00:00
vultr Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
.shellcheckrc ci: add shellcheck linting infrastructure 2026-02-08 01:08:34 +00:00
AUTONOMOUS_REFACTORING_COMPLETE.md Autonomous refactoring: 5 rounds, ~1,400 lines eliminated, production-ready 2026-02-08 00:06:46 +00:00
CLAUDE.md Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
improve.sh refactor: add -e flag to improve.sh error handling 2026-02-08 03:21:18 +00:00
manifest.json Add guardrails: CLAUDE.md rules, hooks, pre-commit validation (#33) 2026-02-07 20:02:19 -08:00
README.md Simplify README: focus on CLI, drop per-cloud inline docs (#34) 2026-02-07 20:05:24 -08:00
REFACTORING_SUMMARY.md Autonomous refactoring: 5 rounds, ~1,400 lines eliminated, production-ready 2026-02-08 00:06:46 +00:00

Spawn

Launch any AI coding agent on any cloud, pre-configured with OpenRouter.

Install

curl -fsSL https://raw.githubusercontent.com/OpenRouterTeam/spawn/main/cli/install.sh | bash

Usage

spawn                         # Interactive picker
spawn <agent> <cloud>         # Launch directly
spawn list                    # Show the full matrix

Examples

spawn claude sprite           # Claude Code on Sprite
spawn aider hetzner           # Aider on Hetzner Cloud
spawn goose digitalocean      # Goose on DigitalOcean
spawn codex vultr             # Codex CLI on Vultr

Commands

Command Description
spawn Interactive agent + cloud picker
spawn <agent> <cloud> Launch agent on cloud directly
spawn <agent> Show available clouds for an agent
spawn list Full agent x cloud matrix
spawn agents List all agents
spawn clouds List all cloud providers

Without the CLI

Every combination also works as a one-liner:

bash <(curl -fsSL https://openrouter.ai/lab/spawn/{cloud}/{agent}.sh)

Non-Interactive

Skip all prompts with environment variables:

OPENROUTER_API_KEY=sk-or-v1-xxxxx \
  spawn claude sprite

Each cloud has its own env vars for auth — see the cloud's README.

Agents

Agent Description
Claude Code Anthropic's CLI coding agent
OpenClaw OpenRouter's agent framework
NanoClaw WhatsApp-based AI agent
Aider AI pair programming in the terminal
Goose Block's model-agnostic coding agent
Codex CLI OpenAI's open-source coding agent
Open Interpreter Natural language computer control
Gemini CLI Google's coding agent
Amazon Q AWS's AI coding assistant
Cline Open-source terminal coding agent
gptme Personal AI agent with tools

Clouds

Cloud Type Auth
Sprite Managed VM sprite login
Hetzner REST API HCLOUD_TOKEN
DigitalOcean REST API DO_API_TOKEN
Vultr REST API VULTR_API_KEY
Linode REST API LINODE_API_TOKEN
Lambda REST API LAMBDA_API_KEY
AWS Lightsail AWS CLI aws configure
GCP gcloud CLI gcloud auth login
E2B SDK E2B_API_KEY
Modal SDK modal setup
Fly.io CLI + API FLY_API_TOKEN

Development

git clone https://github.com/OpenRouterTeam/spawn.git
cd spawn
git config core.hooksPath .githooks