Plugin directory / Developer / dsh-proxy-config
dsh-proxy-config
Unverified lhf6623
What it does
DeepSeek Harness proxy config plugin: injects HTTP/SOCKS proxy into process.env so plugin installs (pnpm/git) use it
Unverified — not yet verified
DeepSeek Harness proxy config plugin: injects HTTP/SOCKS proxy into process.env so plugin installs (pnpm/git) use it Not yet verified — install and test it yourself.
“Unverified” means our automated CI has not yet installed this plugin. Feature descriptions and version compatibility are the author’s claims. This is not a security audit and not an endorsement of third-party code.
README
dsh-proxy-config
DeepSeek Harness 代理配置插件:配置代理后自动生效,让 Harness 访问外网(LLM API / Web 搜索 / MCP / 插件安装等)以及它拉起的 pnpm / git 子进程都自动走 HTTP / SOCKS 代理;本机 / 回环 / 内网(127.0.0.1 / localhost / ::1 / 私有网段 / .local)直连不绕代理。
解决场景:国内访问
codeload.github.com等目标被墙/限速导致插件安装卡死,或 Harness 自身出网(DeepSeek API、网页抓取、MCP)走不了代理。
安装
dsh plugin --profile web add github:lhf6623/dsh-proxy-config
安装后重启 harness,在 设置 → 插件 → 网络代理 里填写代理地址即可。
该插件是 host 端 bundle 插件,改动后需要重启 harness 才会加载;Web 页面本身不会自动热更新。
快速开始
- 打开设置页 设置 → 插件 → 网络代理。
- 填写代理地址(HTTP 或 SOCKS 任选其一即可):
- HTTP/HTTPS:
http://127.0.0.1:7890 - SOCKS5:
socks5://127.0.0.1:7891
- HTTP/HTTPS:
- 点 保存。默认「启用代理」为打开,填了有效代理地址就自动生效。
关闭:把「启用代理」开关关掉再保存即可(保留代理地址,仅暂停使用);点 清除配置 会删除配置并清空代理变量。
配置项
| 字段 | 说明 | 示例 |
|---|---|---|
enabled |
是否启用代理(默认 true) |
true / false |
http |
HTTP/HTTPS 转发代理,同时作为 https 代理 | http://127.0.0.1:7890 |
socks |
SOCKS5 / SOCKS4 代理 | socks5://127.0.0.1:7891 |
- 两个字段可只填一个;同时填时 HTTP 代理优先用于进程内请求(HTTP 与 HTTPS 目标)。
- 配置持久化到
$DSH_HOME/proxy-config.json。 - 未配置代理时插件完全透明,不影响现有网络。
生效范围
| 场景 | 是否走代理 |
|---|---|
| Harness 自身访问外网(LLM API / Web 搜索 / MCP) | ✅ 自动走代理 |
| 插件安装时 spawn 的 pnpm / git / npm / curl 等子进程 | ✅ 自动走代理 |
本机 / 回环 / 内网目标(127.0.0.1、localhost、::1、私有网段、.local) |
❌ 直连,不绕代理 |
| 「启用代理」开关关闭 | ❌ 全部直连(配置仍保留) |
| 未配置代理 | ❌ 全部直连 |
工作原理
- 子进程:插件把
http_proxy/https_proxy/all_proxy/no_proxy写入process.env,pnpm / git 等子进程自动继承。 - Harness 自身出网:宿主 Node 进程的全局
fetch(undici)本不读环境变量代理,插件安装了一个 undici 全局 Dispatcher 作为出口路由:- 命中
no_proxy的目标 → 直连; - 其余目标 → 走 HTTP / HTTPS CONNECT 隧道或 SOCKS5。
- 底层是 undici 原生 fetch 引擎,因此保留标准
Response语义(含 SSE 流式 body)、重定向、默认请求头与证书校验。
- 命中
- 即时生效:每次保存设置后立即重建并应用 Dispatcher / 环境变量。
注意
- 新增依赖
undici,安装时由 pnpm 自动拉取。 - Harness 启动环境若已另有代理,本插件会用配置的代理覆盖对应的进程内出口与子进程环境变量;不需用时可用「启用代理」开关临时关闭,或点「清除配置」彻底移除。
no_proxy默认合并了回环、链路本地、私有网段(10.0.0.0/8、172.16.0.0/12、192.168.0.0/16、169.254.0.0/16、fc00::/7、fe80::/10)及*.local,并保留你已有的NO_PROXY条目。
卸载 / 清理
- 在「网络代理」设置页先点 清除配置。
- 执行:
dsh plugin --profile web remove dsh-proxy-config
「清除配置」会删除 $DSH_HOME/proxy-config.json、移除进程内代理变量,并还原全局 dispatcher;插件被停止时也会自动清理,不残留。
许可证
MIT
Install
Install the catalog once, then DeepSeek Harness can find and install any plugin from this site automatically:
dsh plugin add dshbase-catalog Then say "install dsh-proxy-config for me" — your agent finds it in the directory and installs it. Docs: dshbase-catalog · verified packs.
This plugin is GitHub source (not published to npm) — install it straight from the repo:
Web profile:
dsh plugin --profile web add github:lhf6623/dsh-proxy-config Headless (CLI) profile:
dsh plugin --profile headless add github:lhf6623/dsh-proxy-config Test report
Not yet L3-verified — see failure note below if we already ran it.
2026-08-27 · flagged webonly Note: 验证: web-only;待 L4 web CDP;L4 web CDP runtime-fail on dsh 0.1.0-rc.8. Browse all pending failures →