基于 Ubuntu24 Docker 的远程开发环境,包含多个 AI CLI + CC-Switch。
- 远程桌面: 通过 noVNC Web 界面访问 CC-Switch 桌面
- AI CLI 工具: Gemini CLI、Claude CLI、Cursor CLI、Codex CLI
- Web 工具: Web 终端 (gotty)、文件服务器 (dufs)、Jupyter Notebook
- 开发运行时: 预装 Golang 和 Node.js
- 持久化配置: 所有工具配置保存到主机
- 已安装 Docker
# 快速安装 Docker
curl -SsL https://install.xiechengqi.top/install/Docker/install.sh | sudo bash# 如需要,创建 .gitconfig
touch .gitconfig
docker run -itd \
--name ai \
--restart=always \
--privileged \
-p 5000:5000 \
-p 2222:2222 \
-p 7700:7700 \
-p 8000:8000 \
-v ${PWD}/.cc-switch:/root/.cc-switch \
-v ${PWD}/.cursor:/root/.cursor \
-v ${PWD}/.gemini:/root/.gemini \
-v ${PWD}/.claude:/root/.claude \
-v ${PWD}/.codex:/root/.codex \
-v ${PWD}/.jupyter:/root/.jupyter \
-v ${PWD}/.gitconfig:/root/.gitconfig \
-v ~/.ssh:/root/.ssh \
fullnode/remote-ai:latest| 服务 | 端口 | URL | 说明 |
|---|---|---|---|
| CC Switch | 7700 | http://localhost:7700 | 远程桌面 |
| Gotty | 2222 | http://localhost:2222 | Web 终端 |
| Dufs | 5000 | http://localhost:5000 | 文件服务器 |
| Jupyter | 8000 | http://localhost:8000 | 获取令牌: docker exec ai jupyter server list |
| 变量 | 说明 | 默认值 |
|---|---|---|
CCSWITCH_NOVNC_PASSWORD |
noVNC 密码 | 无 |
TERMINAL_USER |
gotty 基本认证用户名 | 无 |
TERMINAL_PASSWORD |
gotty 基本认证密码 | 无 |
安全提示:
- 未设置
TERMINAL_USER/TERMINAL_PASSWORD时,Web 终端无身份验证 - 未设置
CCSWITCH_NOVNC_PASSWORD时,远程桌面无密码保护 - 如果公开暴露端口,请设置这些变量
./build.sh./stop.sh