fix: pin macos ssh remote url to loopback

This commit is contained in:
Peter Steinberger
2026-04-26 05:01:14 +01:00
parent 9ed11d6c49
commit b277eac656
10 changed files with 283 additions and 37 deletions

View File

@@ -22,6 +22,11 @@ Remote mode supports two transports:
- **SSH tunnel** (default): Uses `ssh -N -L ...` to forward the gateway port to localhost. The gateway will see the nodes IP as `127.0.0.1` because the tunnel is loopback.
- **Direct (ws/wss)**: Connects straight to the gateway URL. The gateway sees the real client IP.
In SSH tunnel mode, discovered LAN/tailnet hostnames are saved as
`gateway.remote.sshTarget`. The app keeps `gateway.remote.url` on the local
tunnel endpoint, for example `ws://127.0.0.1:18789`, so CLI, Web Chat, and
browser automation all use the same safe loopback transport.
## Prereqs on the remote host
1. Install Node + pnpm and build/install the OpenClaw CLI (`pnpm install && pnpm build && pnpm link --global`).