树莓派(Raspberry Pi)

树莓派(Raspberry Pi)

适用范围

树莓派适合做“低功耗、常驻在线”的个人网关:消息与工具调度在网关上完成,模型通常仍由云端提供(API 模型)。

前置条件

  • 树莓派 4/5(建议 2GB+)
  • Raspberry Pi OS Lite(64-bit)
  • 已启用 SSH 并可稳定联网

推荐步骤(可验证)

1) 系统更新与基础依赖

sudo apt update && sudo apt upgrade -y
sudo apt install -y git curl build-essential

2) 安装 Node.js 22(ARM64)

curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -
sudo apt install -y nodejs
node --version

3) 低内存机器建议加 swap

sudo fallocate -l 2G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
echo '/swapfile none swap sw 0 0' | sudo tee -a /etc/fstab

4) 安装并完成向导

curl -fsSL https://clawd.bot/install.sh | bash
moltbot onboard --install-daemon

5) 验证与访问控制台

moltbot status
moltbot health
sudo systemctl status moltbot

本机用 SSH 隧道访问:

ssh -L 18789:localhost:18789 user@YOUR_PI_HOST

浏览器打开:http://localhost:18789/

注意事项(ARM)

  • 不建议在树莓派上跑本地大模型;更适合作为网关 + 工具/渠道入口。
  • 如果某个技能报 “exec format error”,通常是依赖的二进制没有 ARM64 版本。

进一步阅读

  • Tailscale 远程访问(英文):/en/docs/gateway/tailscale/