remotego - Expose Any CLI as a Public Web Terminal
Mirror any CLI tool in a browser with a public URL. Share your terminal with anyone over the internet.
When to Use
The user wants to:
- - Share their terminal session with someone remotely
- Access a CLI tool from a browser
- Collaborate on a terminal session in real-time
- Expose a local CLI to a public URL
How to Use
remotego is installed globally via npm. Run it with any command:
CODEBLOCK0
Quick Examples
| Goal | Command |
|---|
| Mirror Claude Code | INLINECODE0 |
| Mirror bash |
remotego bash |
| Mirror Python REPL |
remotego python3 -i |
| Mirror vim |
remotego vim |
| Mirror Node.js REPL |
remotego node |
| Custom port |
remotego --port 9000 bash |
| Custom tunnel domain |
remotego --domain myterm.localhost.run bash |
| Pass flags to command |
remotego -- git log --oneline |
Options
| Flag | Description | Default |
|---|
| INLINECODE8 | Local HTTP port | INLINECODE9 |
| INLINECODE10 |
Working directory | Current dir |
|
--domain <domain> | Custom localhost.run domain | Random |
|
--help, -h | Show help | |
Install First (if not installed)
CODEBLOCK1
Or use without installing:
CODEBLOCK2
What Happens
- 1. Spawns the command in a PTY (pseudo-terminal)
- Starts a local HTTP server with xterm.js browser terminal
- Creates a public tunnel via localhost.run
- Opens the browser automatically with a session URL
Security Model
- - A random session UUID is generated on each start
- The session ID is embedded in the URL — only URL holders can connect
- Clients must authenticate within 5 seconds of connecting
Stopping
Press Ctrl+C in the terminal running remotego.
Troubleshooting
| Issue | Solution |
|---|
| INLINECODE14 not found | Install from https://nodejs.org/ |
| Tunnel fails |
Check if SSH port 22 is blocked; falls back to localhost |
| Port in use | Use
--port to specify a different port |
| Browser doesn't open | Manually open the URL shown in terminal output |
remotego - 将任何CLI公开为公共Web终端
在浏览器中通过公共URL镜像任何CLI工具。通过互联网与任何人共享您的终端。
使用场景
用户希望:
- - 与远程用户共享终端会话
- 从浏览器访问CLI工具
- 实时协作处理终端会话
- 将本地CLI暴露到公共URL
使用方法
remotego通过npm全局安装。使用任何命令运行它:
bash
remotego [command-args...] [options]
快速示例
| 目标 | 命令 |
|---|
| 镜像Claude Code | remotego claude |
| 镜像bash |
remotego bash |
| 镜像Python REPL | remotego python3 -i |
| 镜像vim | remotego vim |
| 镜像Node.js REPL | remotego node |
| 自定义端口 | remotego --port 9000 bash |
| 自定义隧道域名 | remotego --domain myterm.localhost.run bash |
| 向命令传递参数 | remotego -- git log --oneline |
选项
| 标志 | 描述 | 默认值 |
|---|
| --port <port> | 本地HTTP端口 | 7681 |
| --cwd <dir> |
工作目录 | 当前目录 |
| --domain
| 自定义localhost.run域名 | 随机 |
| --help, -h | 显示帮助 | |
先安装(如果未安装)
bash
npm install -g @remotego/remotego
或者无需安装直接使用:
bash
npx @remotego/remotego bash
工作原理
- 1. 在PTY(伪终端)中启动命令
- 启动带有xterm.js浏览器终端的本地HTTP服务器
- 通过localhost.run创建公共隧道
- 自动在浏览器中打开会话URL
安全模型
- - 每次启动时生成随机会话UUID
- 会话ID嵌入URL中——只有持有URL的用户才能连接
- 客户端必须在连接后5秒内完成身份验证
停止
在运行remotego的终端中按Ctrl+C。
故障排除
| 问题 | 解决方案 |
|---|
| 未找到node | 从https://nodejs.org/安装 |
| 隧道失败 |
检查SSH端口22是否被屏蔽;回退到localhost |
| 端口被占用 | 使用--port指定其他端口 |
| 浏览器未打开 | 手动打开终端输出中显示的URL |