dsh 有意不支持远程连接(intentionally not supported )

kebyn 2026-08-13 22:16 1

看了看dsh用法,试试ipv6地址不支持,提示只支持expected "127.0.0.1" | "0.0.0.0",按照提示又试了试0.0.0.0,告诉我有意不支持 ^-^


root@local:/data# npx @deepseek-ai/dsh web --help
Usage: dsh --profile web [options]

Serve the DeepSeek Harness browser UI.

Options:
--host <host> bind host
--port <port> listen port; pass 0 to let the OS pick a free one
--trusted-host <authority...> extra authority the /api browser-trust fence accepts (host or host:port; repeatable)
-h, --help show this help

Examples:
dsh --profile web serve on the composed host and port
dsh --profile web --port 8080 serve on another port

root@local:/data# npx @deepseek-ai/dsh web --host '::' --port 80
file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh-app-boot/lib/index.js:1186
throw new Error(`${binName}: ${stage}: ${detail}${stack}`, { cause });
^

Error: dsh: plugin tree failed to load: failed to apply loader entry include (cordis:include): failed to apply loader entry webserver (@deepseek-ai/dsh-host-webserver): invalid config:
- $.host expected "127.0.0.1" | "0.0.0.0" but got "::" (at host)
ValidationError: invalid config:
- $.host expected "127.0.0.1" | "0.0.0.0" but got "::" (at host)
at resolveConfig (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis/lib/index.js:959:27)
at Fiber._resolveConfig (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis/lib/index.js:1346:25)
at Fiber._reload (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis/lib/index.js:1354:24)
at boot (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh-app-boot/lib/index.js:1186:9)
at async runProfile (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh/lib/profile-boot-DG5t9aNs.js:247:14)
at async file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh/lib/bin.js:133:3 {
[cause]: Error: failed to apply loader entry include (cordis:include): failed to apply loader entry webserver (@deepseek-ai/dsh-host-webserver): invalid config:
- $.host expected "127.0.0.1" | "0.0.0.0" but got "::" (at host)
at updateError (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:299:9)
at Entry._init (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:519:10)
at async Entry.init (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:495:4)
at async Entry.update (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:416:37)
at async EntryGroup.create (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:55:4)
at async Proxy.create (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:217:14)
at async mountRootInclude (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh-app-boot/lib/index.js:984:20)
at async boot (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh-app-boot/lib/index.js:1175:3)
at async runProfile (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh/lib/profile-boot-DG5t9aNs.js:247:14)
at async file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh/lib/bin.js:133:3 {
[cause]: Error: failed to apply loader entry webserver (@deepseek-ai/dsh-host-webserver): invalid config:
- $.host expected "127.0.0.1" | "0.0.0.0" but got "::" (at host)
at updateError (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:299:9)
at Entry._await (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:506:10)
at async Entry.init (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:500:3)
at async Entry.update (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:416:37)
at async EntryGroup.create (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:55:4)
at async Promise.allSettled (index 92)
at async EntryGroup.update (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis-plugin-loader/lib/index.js:87:21)
at async Include._apply (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/dsh-app-boot/lib/index.js:238:3) {
[cause]: ValidationError: invalid config:
- $.host expected "127.0.0.1" | "0.0.0.0" but got "::" (at host)
at resolveConfig (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis/lib/index.js:959:27)
at Fiber._resolveConfig (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis/lib/index.js:1346:25)
at Fiber._reload (file:///root/.npm/_npx/1e7f6d9597241db0/node_modules/@deepseek-ai/cordis/lib/index.js:1354:24)
}
}
}

Node.js v24.19.0
root@local:/data# npx @deepseek-ai/dsh web --host 0.0.0.0 --port 80
error: --host 0.0.0.0 is intentionally not supported yet for safety: it would expose remote code execution to the network; use 127.0.0.1 instead
最新回复 (7)
  • gcjer 08-13 22:17
    1

    我装服务器上了 ssh端口转发,把流量伪装成回环

    ssh -L 3080:127.0.0.1:3080 用户名@服务器ip

  • crb1025 08-13 22:18
    2

    socat转发,现在没有鉴权阻止0.0.0.0也合理

  • Dowad 08-13 22:37
    4

    ? 佬,你不能指望一个 Web Server 充当网关的功能啊。稍微套个nginx/caddy/traefik 都可以啊。

  • Dowad 08-13 22:38
    5

    如果加了避免直接0.0.0.0,那是太有人文关怀了,防止默认配置被快速当做一个漏权点。


    即,防呆设计,也可以叫防菜鸟不自觉的打开家门

  • Jsir Hsu 08-13 22:40
    6

    ~/.dsh/profiles/web/cordis.patch.yml下


    - id: webserver
    config:
    host: 0.0.0.0
    port: !!js ctx.webStartup.port ?? 3080
  • 狗蛋 08-18 01:01
    7

    我自己用 Cloudflare Tunnel + Access 接的,挺稳。
    链路是:手机浏览器 → Cloudflare Access 邮箱认证 → Named Tunnel → 本机 127.0.0.1:3080。DSH 不用改架构,只在公网前面套一层认证墙。
    几个会卡住的点提醒一下:
    DSH 启动必须 --trusted-host <子域名>,不然 /api 直接 403,页面卡在 L…


    看着楼上大佬的发言


    dsh启动的时候 加上信任的域名 就能访问了 和提问了


    但是历史会话好像还是加载不出来 不知道怎么搞


    实在不行 我可能就投奔 民间插件了 我看有很多佬手搓 插件了




    本帖使用社区开源推广,符合推广要求。我申明并遵循社区要求的以下内容:

    ** 我的帖子已经打上 开源推广 标签:** 是

    ** 我的开源项目完整开源,无未开源部分:** 是

    ** 我的开源项目已链接认可 LINUX DO 社区:** 是

    ** 我帖子内的项目介绍,AI 生成、润色内容部分已截图发出:** 是

    ** 以上选择我承诺是永久有效的,接受社区和佬友监督:** 是

  • FaelanDon 08-18 01:05
    8

    「开源」DeepSeek Harness Remote 安卓版 - 开发调优 - LINUX DO

    佬友可以看看我的项目,提提意见 ^-^

* 帖子来源Linux.do
返回