mirror of
https://github.com/farcasclaudiu/openclaw.git
synced 2026-06-29 15:01:48 +03:00
Docs: update zh-CN translations and pipeline
What: - update zh-CN glossary, TM, and translator prompt - regenerate zh-CN docs and apply targeted fixes - add zh-CN AGENTS pipeline guidance Why: - address terminology/spacing feedback from #6995 Tests: - pnpm build && pnpm check && pnpm test
This commit is contained in:
@@ -1,86 +1,86 @@
|
||||
---
|
||||
read_when: 通过 SSH 将 macOS 应用连接到远程 Gateway网关
|
||||
summary: 为 OpenClaw.app 连接远程 Gateway网关设置 SSH 隧道
|
||||
title: 远程 Gateway网关设置
|
||||
read_when: Connecting the macOS app to a remote gateway over SSH
|
||||
summary: OpenClaw.app 连接远程 Gateway 网关的 SSH 隧道设置
|
||||
title: 远程 Gateway 网关设置
|
||||
x-i18n:
|
||||
generated_at: "2026-02-01T20:35:41Z"
|
||||
generated_at: "2026-02-03T07:48:37Z"
|
||||
model: claude-opus-4-5
|
||||
provider: pi
|
||||
source_hash: b1ae266a7cb4911b82ae3ec6cb98b1b57aca592aeb1dc8b74bbce9b0ea9dd1d1
|
||||
source_path: gateway/remote-gateway-readme.md
|
||||
workflow: 14
|
||||
workflow: 15
|
||||
---
|
||||
|
||||
# 使用远程 Gateway网关运行 OpenClaw.app
|
||||
# 使用远程 Gateway 网关运行 OpenClaw.app
|
||||
|
||||
OpenClaw.app 使用 SSH 隧道连接到远程 Gateway网关。本指南将介绍如何进行设置。
|
||||
OpenClaw.app 使用 SSH 隧道连接到远程 Gateway 网关。本指南向你展示如何设置。
|
||||
|
||||
## 概述
|
||||
|
||||
```
|
||||
┌─────────────────────────────────────────────────────────────┐
|
||||
│ 客户端机器 │
|
||||
│ Client Machine │
|
||||
│ │
|
||||
│ OpenClaw.app ──► ws://127.0.0.1:18789(本地端口) │
|
||||
│ OpenClaw.app ──► ws://127.0.0.1:18789 (local port) │
|
||||
│ │ │
|
||||
│ ▼ │
|
||||
│ SSH 隧道 ──────────────────────────────────────────────────│
|
||||
│ SSH Tunnel ────────────────────────────────────────────────│
|
||||
│ │ │
|
||||
└─────────────────────┼──────────────────────────────────────┘
|
||||
│
|
||||
▼
|
||||
┌─────────────────────────────────────────────────────────────┐
|
||||
│ 远程机器 │
|
||||
│ Remote Machine │
|
||||
│ │
|
||||
│ Gateway网关 WebSocket ──► ws://127.0.0.1:18789 ──► │
|
||||
│ Gateway WebSocket ──► ws://127.0.0.1:18789 ──► │
|
||||
│ │
|
||||
└─────────────────────────────────────────────────────────────┘
|
||||
```
|
||||
|
||||
## 快速设置
|
||||
|
||||
### 第 1 步:添加 SSH 配置
|
||||
### 步骤 1:添加 SSH 配置
|
||||
|
||||
编辑 `~/.ssh/config` 并添加:
|
||||
|
||||
```ssh
|
||||
Host remote-gateway
|
||||
HostName <REMOTE_IP> # 例如 172.27.187.184
|
||||
User <REMOTE_USER> # 例如 jefferson
|
||||
HostName <REMOTE_IP> # e.g., 172.27.187.184
|
||||
User <REMOTE_USER> # e.g., jefferson
|
||||
LocalForward 18789 127.0.0.1:18789
|
||||
IdentityFile ~/.ssh/id_rsa
|
||||
```
|
||||
|
||||
将 `<REMOTE_IP>` 和 `<REMOTE_USER>` 替换为你的实际值。
|
||||
将 `<REMOTE_IP>` 和 `<REMOTE_USER>` 替换为你的值。
|
||||
|
||||
### 第 2 步:复制 SSH 密钥
|
||||
### 步骤 2:复制 SSH 密钥
|
||||
|
||||
将你的公钥复制到远程机器(需输入一次密码):
|
||||
将你的公钥复制到远程机器(输入一次密码):
|
||||
|
||||
```bash
|
||||
ssh-copy-id -i ~/.ssh/id_rsa <REMOTE_USER>@<REMOTE_IP>
|
||||
```
|
||||
|
||||
### 第 3 步:设置 Gateway网关令牌
|
||||
### 步骤 3:设置 Gateway 网关令牌
|
||||
|
||||
```bash
|
||||
launchctl setenv OPENCLAW_GATEWAY_TOKEN "<your-token>"
|
||||
```
|
||||
|
||||
### 第 4 步:启动 SSH 隧道
|
||||
### 步骤 4:启动 SSH 隧道
|
||||
|
||||
```bash
|
||||
ssh -N remote-gateway &
|
||||
```
|
||||
|
||||
### 第 5 步:重启 OpenClaw.app
|
||||
### 步骤 5:重启 OpenClaw.app
|
||||
|
||||
```bash
|
||||
# 退出 OpenClaw.app(⌘Q),然后重新打开:
|
||||
# Quit OpenClaw.app (⌘Q), then reopen:
|
||||
open /path/to/OpenClaw.app
|
||||
```
|
||||
|
||||
应用现在将通过 SSH 隧道连接到远程 Gateway网关。
|
||||
应用现在将通过 SSH 隧道连接到远程 Gateway 网关。
|
||||
|
||||
---
|
||||
|
||||
@@ -90,7 +90,7 @@ open /path/to/OpenClaw.app
|
||||
|
||||
### 创建 PLIST 文件
|
||||
|
||||
将以下内容保存为 `~/Library/LaunchAgents/bot.molt.ssh-tunnel.plist`:
|
||||
将此保存为 `~/Library/LaunchAgents/bot.molt.ssh-tunnel.plist`:
|
||||
|
||||
```xml
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
@@ -121,11 +121,11 @@ launchctl bootstrap gui/$UID ~/Library/LaunchAgents/bot.molt.ssh-tunnel.plist
|
||||
|
||||
隧道现在将:
|
||||
|
||||
- 在你登录时自动启动
|
||||
- 崩溃后自动重启
|
||||
- 登录时自动启动
|
||||
- 崩溃时重新启动
|
||||
- 在后台持续运行
|
||||
|
||||
旧版说明:如果存在残留的 `com.openclaw.ssh-tunnel` LaunchAgent,请将其删除。
|
||||
旧版注意事项:如果存在任何遗留的 `com.openclaw.ssh-tunnel` LaunchAgent,请将其删除。
|
||||
|
||||
---
|
||||
|
||||
@@ -154,11 +154,11 @@ launchctl bootout gui/$UID/bot.molt.ssh-tunnel
|
||||
|
||||
## 工作原理
|
||||
|
||||
| 组件 | 功能说明 |
|
||||
| ------------------------------------ | ------------------------------------------- |
|
||||
| `LocalForward 18789 127.0.0.1:18789` | 将本地端口 18789 转发到远程端口 18789 |
|
||||
| `ssh -N` | 仅进行端口转发的 SSH 连接(不执行远程命令) |
|
||||
| `KeepAlive` | 隧道崩溃时自动重启 |
|
||||
| `RunAtLoad` | 在代理加载时启动隧道 |
|
||||
| 组件 | 功能 |
|
||||
| ------------------------------------ | ------------------------------------- |
|
||||
| `LocalForward 18789 127.0.0.1:18789` | 将本地端口 18789 转发到远程端口 18789 |
|
||||
| `ssh -N` | SSH 不执行远程命令(仅端口转发) |
|
||||
| `KeepAlive` | 隧道崩溃时自动重启 |
|
||||
| `RunAtLoad` | 代理加载时启动隧道 |
|
||||
|
||||
OpenClaw.app 连接到客户端机器上的 `ws://127.0.0.1:18789`。SSH 隧道将该连接转发到运行 Gateway网关的远程机器的 18789 端口。
|
||||
OpenClaw.app 连接到你的客户端机器上的 `ws://127.0.0.1:18789`。SSH 隧道将该连接转发到运行 Gateway 网关的远程机器的端口 18789。
|
||||
|
||||
Reference in New Issue
Block a user