mirror of
https://github.com/OpenRouterTeam/spawn.git
synced 2026-05-10 12:20:07 +00:00
Two fixes for persistent Fly.io auth failures: 1. shared/common.sh — _load_token_from_config(): When the saved token fails the security character check, auto-delete the corrupt config file instead of silently returning 1. This prevents the user from being stuck in a loop where every run loads a malformed token (from a previous failed auth attempt) and immediately fails. Message changed from error to warn: "Saved token is malformed — clearing cached credentials." 2. fly/lib/common.sh — _try_flyctl_auth() and _try_fly_browser_auth(): Pipe 'fly auth token' output through 'head -1' to capture only the first line. Newer flyctl versions may print warnings/metadata after the token on subsequent lines; previously these got concatenated into the token string via $() and could introduce characters that fail the security validator (newlines stripped by _sanitize_fly_token, but concatenated text from warning lines could contain unusual chars). Co-authored-by: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| lib | ||
| claude.sh | ||
| codex.sh | ||
| kilocode.sh | ||
| openclaw.sh | ||
| opencode.sh | ||
| README.md | ||
| zeroclaw.sh | ||
Fly.io
Fly.io Machines via REST API and flyctl CLI. Fly.io
Agents
Claude Code
bash <(curl -fsSL https://openrouter.ai/labs/spawn/fly/claude.sh)
OpenClaw
bash <(curl -fsSL https://openrouter.ai/labs/spawn/fly/openclaw.sh)
ZeroClaw
bash <(curl -fsSL https://openrouter.ai/labs/spawn/fly/zeroclaw.sh)
Codex CLI
bash <(curl -fsSL https://openrouter.ai/labs/spawn/fly/codex.sh)
OpenCode
bash <(curl -fsSL https://openrouter.ai/labs/spawn/fly/opencode.sh)
Kilo Code
bash <(curl -fsSL https://openrouter.ai/labs/spawn/fly/kilocode.sh)
Non-Interactive Mode
FLY_APP_NAME=dev-mk1 \
FLY_API_TOKEN=your-token \
OPENROUTER_API_KEY=sk-or-v1-xxxxx \
bash <(curl -fsSL https://openrouter.ai/labs/spawn/fly/claude.sh)
Environment Variables
| Variable | Description | Default |
|---|---|---|
FLY_API_TOKEN |
Fly.io API token | (prompted or from flyctl auth) |
FLY_APP_NAME |
App name | (prompted) |
FLY_REGION |
Deployment region | iad |
FLY_VM_SIZE |
VM size | shared-cpu-1x |
FLY_VM_MEMORY |
VM memory (MB) | 1024 |
FLY_ORG |
Organization slug | personal |
OPENROUTER_API_KEY |
OpenRouter API key | (OAuth or prompted) |