版本:v0.11.0 (v2026.4.23) · 更新于:2026年4月
| 配置 | 推荐场景 | 参考价格 |
|---|---|---|
| 1核2G | 单平台运行(如只有 Telegram) | 约50元/月 |
| 2核4G | 多平台 + Skills + MCP | 约80元/月 |
| 4核8G | 商用量、多实例 | 约150元/月 |
ssh ubuntu@你的服务器IP
curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash - sudo apt install -y nodejs git node --version # 确认输出 v20.x
git clone https://github.com/NousResearch/hermes-agent.git cd hermes-agent npm install
cp config.example.yaml config.yaml nano config.yaml
需要配置的关键项:
安装 PM2 让 Hermes 在后台持续运行:
sudo npm install -g pm2 pm2 start npm --name hermes -- start pm2 save pm2 startup # 设置为开机自启
| 命令 | 说明 |
|---|---|
pm2 status | 查看运行状态 |
pm2 logs hermes | 查看实时日志 |
pm2 restart hermes | 重启 Hermes |
pm2 stop hermes | 停止 Hermes |
sudo ufw allow ssh sudo ufw enable
只开放 SSH 端口,其他端口按需开放。
不要在 config.yaml 中硬编码 API Key,改用环境变量:
export OPENAI_API_KEY="sk-xxx" export ANTHROPIC_API_KEY="sk-ant-xxx"
然后在 config.yaml 中使用 $OPENAI_API_KEY 引用。
cd ~/hermes-agent git pull origin main npm install pm2 restart hermes
检查 config.yaml 中的平台配置:确认 Bot Token 正确、平台已启用。查看日志:pm2 logs hermes
减少同时启用的平台数量,或者升级服务器配置。
运行 pm2 startup 并按提示执行输出中的命令。
xia007 · 养虾人的导航站