--- title: "Vibe-Kanban + OpenCode 在 Ubuntu Server 上安装与管理指南" type: source tags: [ubuntu, vibe-coding, vibe-kanban, opencode, pm2, node, nvm] date: 2026-04-15 --- ## Source File - [[raw/Vibe Coding/Vibe-Kanban + OpenCode 在 Ubuntu Server 上安装与管理指南.md]] ## Summary - 核心主题:在 Ubuntu Server 上以非 root 用户(shenwei)安装 Node 20、Vibe-Kanban 与 OpenCode,并通过 pm2 管理进程 - 问题域:权限冲突、端口占用、executor 启动失败、I/O error - 方法/机制:nvm 管理 Node 版本 → npm 全局安装 vibe-kanban + opencode → pm2 管理进程 → RUST_LOG=debug 调试 - 结论/价值:不要用 root 启动;vibe-kanban 自动 spawn executor;pm2 只管理 vibe-kanban,executor 随进程管理 ## Key Claims - nvm 管理 Node 版本(v0.39.7),安装 Node 20,nvm alias default 20 - 不要用 root 启动 OpenCode serve,vibe-kanban 会自动 spawn executor - RUST_LOG=debug HOST=0.0.0.0 PORT=9999 npx vibe-kanban 启动,executor 在随机端口 - pm2 start "RUST_LOG=debug HOST=0.0.0.0 PORT=9999 npx vibe-kanban" --name vibe-kanban - pm2 startup systemd -u shenwei --hp /home/shenwei 生成启动脚本 - I/O error 通常是 executor 没启动或端口被占用 - 清理旧工作树:rm -rf /var/tmp/vibe-kanban/worktrees/* 和 ~/.vibe-kanban ## Key Quotes > "不要用 root 启动 OpenCode serve,vibe-kanban 会自动 spawn executor" — 操作规范 > "pm2 只管理 vibe-kanban,executor 随进程一起管理" — 进程管理原则 ## Key Concepts - [[nvm]]:Node Version Manager,通过 curl -fsSL 安装,管理多个 Node 版本 - [[pm2]]:进程管理器,pm2 start/pm2 logs/pm2 save/pm2 startup systemd - [[Vibe-Kanban]]:AI 结对编程任务看板,Web UI(PORT 9999)+ executor 随机端口 - [[OpenCode Executor]]:vibe-kanban spawn 的 AI 编程执行器,随机端口运行 ## Key Entities - [[shenwei]]:Ubuntu 服务器非 root 用户,Vibe-Kanban + OpenCode 安装操作者 ## Connections - [[nvm]] ← 安装工具 ← [[Node 20]] - [[Vibe-Kanban]] ← spawns ← [[OpenCode Executor]] - [[pm2]] ← 管理 ← [[Vibe-Kanban]]