更新系统包索引
安装 curl
通过 NodeSource 安装最新稳定 LTS 版本
# 添加 NodeSource 仓库并安装curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -sudo apt-get install -y nodejs
设置淘宝镜像:
npm config set registry https://registry.npmmirror.com
二、安装 OpenClaw
curl -fsSL https://openclaw.ai/install.sh | bash
安装完成后,如果执行 which openclaw 找不到命令,需要手动配置 PATH。首先,检查 openclaw 是否在 PATH 中:如果输出 /bin/bash,使用 ~/.bashrc如果输出 /bin/zsh,使用 ~/.zshrcecho 'export PATH="$(npm prefix -g)/bin:$PATH"' >> ~/.bashrc
在本地电脑执行,按提示输入远程linux云主机密码即可:ssh -N -L 18789:127.0.0.1:18789 ubuntu@你的云主机IP
携带部署过程中生成的Dashboard link在本地进行访问,如下图:http://localhost:18789/#token=你的token