RestRegular/dsh-pocket ↗★ 0

@restregular/dsh-pocket

Pocket — 把本机 DeepSeek Harness 装进口袋:本地起移动端 Web 服务并支持内外网隧道穿透,在手机上查看会话、流式输出与工具调用,并反向发送指令。 · Pocket for DeepSeek Harness: a mobile web surface with LAN and tunnel access to sessions, live streams, and tool calls. 适合需要通过手机随时随地查看会话、流式输出并审批工具调用的用户。

パッケージ
@restregular/dsh-pocket
互換性
未検証
バージョン
0.7.2
ライセンス
MIT
最終更新
2026/10/20

インストール

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:RestRegular/dsh-pocket

ドキュメント

README 全文を読む ↗

配置

插件行 id 为 dsh-pocket,默认配置见 cordis.patch.yml。

字段默认说明
port8790移动端监听端口;被占用时自动向后找 10 个端口。0 表示随机端口。
lanfalse(本仓库 patch 里为 true)是否绑定 0.0.0.0 允许局域网访问;关掉时只绑 127.0.0.1,但隧道仍可用。
tunnelautoauto / cloudflared / localtunnel / localhost.run / ssh / custom / off。
autoStarttrueHost 启动后是否自动拉起隧道。
publicUrl无已有反向代理或固定域名时直接使用它,不再起隧道进程。
cloudflaredPath无指定 cloudflared 可执行文件;留空时优先用随包二进制,其次 PATH。
customCommand无tunnel: custom 时执行;%PORT% 会被替换成本地端口,输出里第一个公网 URL 视为就绪。
sshHost无自有服务器地址;设置后可将 tunnel 设为 ssh。
sshUserrootSSH 用户名;请使用免密公钥登录。
sshPort22SSH 端口。
sshKeyPath无SSH 私钥路径;支持 ~/...。
sshRemotePort8790SSH 在服务器 127.0.0.1 上绑定的反向转发端口。
sshExposePort80服务器上 Node TCP 代理监听的公网端口;需在防火墙/安全组放行。
sshExposeHost0.0.0.0服务器 TCP 代理绑定地址;若用 Nginx/Caddy 反代可设为 127.0.0.1。
sshPublicUrl无自有域名/HTTPS 入口;设置后二维码使用它,而不是 http://:。
token自动生成固定访问令牌;留空时使用 ~/.dsh/pocket/state.json 里持久化的令牌。

用自有服务器转发

tunnel: ssh 不要求服务器开启 GatewayPorts,也不改 sshd:

  1. SSH 建立 -R 127.0.0.1:sshRemotePort:127.0.0.1:。
  2. SSH 在服务器上启动一个很小的 Node TCP 代理,监听 sshExposeHost:sshExposePort,转发到 127.0.0.1:sshRemotePort。
  3. 手机访问 sshPublicUrl,未设置时访问 http://[:sshExposePort]。

示例:

tunnel: ssh
sshHost: 203.0.113.10
sshUser: root
sshKeyPath: ~/.ssh/id_ed25519
sshPort: 22
sshRemotePort: 8790
sshExposePort: 80