From 09d9f597accafda7614437ad6a18cb2c54640ffd Mon Sep 17 00:00:00 2001 From: A <258483684+la14-1@users.noreply.github.com> Date: Sat, 21 Feb 2026 15:58:05 -0800 Subject: [PATCH] fix: use openclaw curl installer to prevent fly ssh hang (#1640) bun install -g openclaw spawns child processes that keep stdout/stderr FDs open, preventing fly ssh console from detecting EOF. Replace with the official curl installer (--no-onboard) which handles Node detection and cleanup without leaving orphan processes on the pipe. See: https://docs.openclaw.ai/install Co-authored-by: Claude Co-authored-by: Claude Opus 4.6 (1M context) --- cli/package.json | 2 +- cli/src/fly/agents.ts | 2 +- test/mock-curl-script.sh | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cli/package.json b/cli/package.json index fda546d5..f3d45f1b 100644 --- a/cli/package.json +++ b/cli/package.json @@ -1,6 +1,6 @@ { "name": "@openrouter/spawn", - "version": "0.5.27", + "version": "0.5.28", "type": "module", "bin": { "spawn": "cli.js" diff --git a/cli/src/fly/agents.ts b/cli/src/fly/agents.ts index 3755bcd2..9adb0473 100644 --- a/cli/src/fly/agents.ts +++ b/cli/src/fly/agents.ts @@ -349,7 +349,7 @@ export const agents: Record = { install: () => installAgent( "openclaw", - "source ~/.bashrc && { (bun install -g openclaw >/dev/null 2>&1) || npm install -g openclaw@latest; }", + "curl -fsSL https://openclaw.ai/install.sh | bash -s -- --no-onboard", ), envVars: (apiKey) => [ `OPENROUTER_API_KEY=${apiKey}`, diff --git a/test/mock-curl-script.sh b/test/mock-curl-script.sh index 292a4f28..64c96e37 100644 --- a/test/mock-curl-script.sh +++ b/test/mock-curl-script.sh @@ -34,7 +34,7 @@ _parse_args() { _maybe_inject_error() { [ -n "${MOCK_ERROR_SCENARIO:-}" ] || return 1 case "$URL" in - *openrouter.ai*|*raw.githubusercontent.com*|*claude.ai/install*|*bun.sh*|*nodesource*|*nodejs.org*|*opencode*|*zeroclaw*|*pip.pypa.io*|*get.docker.com*|*npmjs.org*|*github.com/*/releases*) + *openrouter.ai*|*raw.githubusercontent.com*|*claude.ai/install*|*bun.sh*|*nodesource*|*nodejs.org*|*openclaw.ai*|*opencode*|*zeroclaw*|*pip.pypa.io*|*get.docker.com*|*npmjs.org*|*github.com/*/releases*) return 1 ;; esac case "${MOCK_ERROR_SCENARIO}" in @@ -65,7 +65,7 @@ _maybe_inject_error() { _handle_special_urls() { case "$URL" in - *claude.ai/install*|*bun.sh*|*nodesource*|*nodejs.org*|*opencode*install*|*zeroclaw*install*|\ + *claude.ai/install*|*bun.sh*|*nodesource*|*nodejs.org*|*openclaw.ai*|*opencode*install*|*zeroclaw*install*|\ *pip.pypa.io*|*get.docker.com*|*install.python-poetry.org*|\ *npmjs.org*|*deb.nodesource.com*|*github.com/*/releases*|*cli.github.com*) printf '#!/bin/bash\nexit 0\n'