spawn/hetzner
L fffb3591c4
feat: wire shared/github-auth.sh into all agent flows (#1216)
* feat: wire shared/github-auth.sh into all agent flows

Add offer_github_auth() to shared/common.sh and call it from the
inject_env_vars_* functions so all agent flows automatically offer
GitHub CLI setup after env var injection — no per-script changes needed.

Changes:
- shared/common.sh: add offer_github_auth() function, call it from
  inject_env_vars_ssh() and inject_env_vars_local()
- sprite/lib/common.sh: call offer_github_auth() from
  inject_env_vars_sprite()
- OVH is covered automatically (inject_env_vars_ovh delegates to
  inject_env_vars_ssh)

Behavior:
- Prompts "Set up GitHub CLI (gh) on this machine? (y/N):"
- Defaults to No (non-blocking for users who don't need it)
- Skippable via SPAWN_SKIP_GITHUB_AUTH=1 env var for CI/automation
- Uses safe_read for curl|bash compatibility
- Downloads and runs shared/github-auth.sh on the remote VM

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* refactor: add shared agent setup helpers, deduplicate hetzner scripts (#1236)

Add 5 composable helper functions to shared/common.sh (install_agent,
verify_agent, get_or_prompt_api_key, inject_env_vars_cb, launch_session)
that use the same callback pattern as offer_github_auth and
setup_claude_code_config. Refactor all 15 hetzner agent scripts to use
them, reducing total line count from 868 to 579 (-33%).

Phase 1 of multi-phase rollout — remaining clouds to follow.

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-02-15 23:00:53 -08:00
..
lib refactor: reduce complexity in OAuth and Hetzner validation functions (#1132) 2026-02-14 17:43:05 -05:00
aider.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
amazonq.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
claude.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
cline.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
codex.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
continue.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
gemini.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
goose.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
gptme.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
interpreter.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
kilocode.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
nanoclaw.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
openclaw.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
opencode.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
plandex.sh feat: wire shared/github-auth.sh into all agent flows (#1216) 2026-02-15 23:00:53 -08:00
README.md refactor: replace Python with jq in Hetzner lib, fix /lab → /labs URLs (#827) 2026-02-12 23:14:11 -08:00

Hetzner Cloud

Hetzner Cloud servers via REST API. Hetzner Cloud

Agents

Claude Code

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/claude.sh)

OpenClaw

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/openclaw.sh)

NanoClaw

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/nanoclaw.sh)

Aider

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/aider.sh)

Goose

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/goose.sh)

Codex CLI

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/codex.sh)

Open Interpreter

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/interpreter.sh)

Gemini CLI

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/gemini.sh)

Amazon Q CLI

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/amazonq.sh)

Cline

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/cline.sh)

gptme

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/gptme.sh)

OpenCode

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/opencode.sh)

Plandex

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/plandex.sh)

Kilo Code

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/kilocode.sh)

Continue

bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/continue.sh)

Non-Interactive Mode

HETZNER_SERVER_NAME=dev-mk1 \
HCLOUD_TOKEN=your-token \
OPENROUTER_API_KEY=sk-or-v1-xxxxx \
  bash <(curl -fsSL https://openrouter.ai/labs/spawn/hetzner/claude.sh)