dsh-drydock 1.1.3 → 1.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +80 -59
- package/README.md +17 -14
- package/bin/drydock-update.mjs +5 -13
- package/lib/client.js +47 -50
- package/lib/evidence-schema.mjs +2 -2
- package/lib/index.js +118 -18
- package/lib/remote.js +17 -6
- package/lib/self-update.mjs +32 -0
- package/package.json +31 -29
- package/schema/badge-v1.json +2 -2
- package/schema/evidence-v1.json +3 -2
- package/schema/matrix-v1.json +4 -3
package/README.en.md
CHANGED
|
@@ -2,118 +2,139 @@
|
|
|
2
2
|
|
|
3
3
|
# DSH engine drydock (dsh-drydock)
|
|
4
4
|
|
|
5
|
-
> **When the engine won't start, it is still there.** A **boot-time reliability toolchain** for [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness):
|
|
5
|
+
> **When the engine won't start, it is still there.** A **boot-time reliability toolchain** for [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness): pre-boot self-check, broken-plugin quarantine and engine rescue (3081 / 3082) in separate processes and ports, plus a tidy plugin manager.
|
|
6
6
|
>
|
|
7
7
|
> The official page and plugin markets handle **getting plugins in**; the drydock handles **what happens afterwards** — undo a bad install, rescue a dead engine. *It fixes this boot; we fix why the next one would break.*
|
|
8
8
|
|
|
9
9
|
 
|
|
10
10
|
   
|
|
11
11
|
|
|
12
|
-
> Community plugin — not an official DSH package. npm: `dsh-drydock` (formerly `dsh-plugin-manager-pro`, which is deprecated on npm but not deleted
|
|
12
|
+
> Community plugin — not an official DSH package. npm: `dsh-drydock` (formerly `dsh-plugin-manager-pro`, which is deprecated on npm but not deleted) · GitHub: [nonentity303/dsh-drydock](https://github.com/nonentity303/dsh-drydock) · Cross-platform (Windows / macOS / Linux).
|
|
13
13
|
>
|
|
14
|
-
> **Current version: 1.1.
|
|
15
|
-
> ⚠️ A brand-new release is blocked by pnpm's **24 h cool-down** (`minimumReleaseAge`) — pin the version explicitly
|
|
14
|
+
> **Current version: 1.1.4** (tracks `master`). **Trust the badges**, not this line: they are the live `latest` / `desktop` / `next` versions. Snapshots (npm page, ADP catalog) may lag — take versions and install commands from the badges, `npm view dsh-drydock dist-tags`, or <https://github.com/nonentity303/dsh-drydock/blob/master/status.json>.
|
|
15
|
+
> ⚠️ A brand-new release is blocked by pnpm's **24 h cool-down** (`minimumReleaseAge`) — pin the version explicitly. Channels: `-desktop.N` = desktop, `-rc.N` = web preview, no suffix = stable.
|
|
16
16
|
|
|
17
|
-
##
|
|
17
|
+
## Five signature features
|
|
18
18
|
|
|
19
19
|
### ① Standalone rescue toolchain — works when the engine does not
|
|
20
|
-
The 3081 launcher (`/` boot page, `/plugins` fallback manager, `/rescue` rescue page) and the 3082 backup rescue daemon run in **separate processes and ports**, independent of the Cordis runtime; `verify / fix / start / stop / status` return explicit exit codes (0 ready / 1 start failed / 2 repair incomplete)
|
|
20
|
+
The 3081 launcher (`/` boot page, `/plugins` fallback manager, `/rescue` rescue page) and the 3082 backup rescue daemon run in **separate processes and ports**, independent of the Cordis runtime; `verify / fix / start / stop / status` return explicit exit codes (0 ready / 1 start failed / 2 repair incomplete). → [docs/RESCUE.md](docs/RESCUE.md)
|
|
21
21
|
|
|
22
22
|
### ② Transactional uninstall / rollback / one-click undo
|
|
23
|
-
Impact preview +
|
|
23
|
+
Impact preview + verdict (safe / caution / risky) → backup → remove → verify every step → **automatic rollback on any failure**; Windows file-lock leftovers are queued in `pendingRemovals`; the last 20 operations are undoable and plugin combinations can be saved as **named scenarios**. → [docs/USAGE.md](docs/USAGE.md)
|
|
24
24
|
|
|
25
25
|
### ③ Update-source trust model + download provenance
|
|
26
|
-
Defaults are npm official `registry.npmjs.org` / GitHub official repo / npmmirror, and **the registry version is authoritative**; custom sources are `authoritative: false` by default and **fallback only
|
|
26
|
+
Defaults are npm official `registry.npmjs.org` / GitHub official repo / npmmirror, and **the registry version is authoritative**; custom sources are `authoritative: false` by default and **fallback only**; `http://` sources are labelled "**plaintext · fallback only**" and need explicit `authoritative: true` + `allowInsecure: true`; only `@deepseek-ai/*` uses the `next` track; auto-install from the downloads folder requires a matching **provenance** record (name + version + source + digest, 7 days). → [docs/SECURITY.md](docs/SECURITY.md)
|
|
27
27
|
|
|
28
28
|
### ④ 3081 fallback page + engine watchdog
|
|
29
|
-
With the engine down, `http://127.0.0.1:3081/plugins` still
|
|
29
|
+
With the engine down, `http://127.0.0.1:3081/plugins` still toggles, updates, uninstalls and restarts it; the resident supervisor also watches engine health — **two consecutive failed probes → it starts the engine**, recycles a hung launcher, and stays quiet after you explicitly stop the engine. → [docs/USAGE.md](docs/USAGE.md)
|
|
30
|
+
|
|
31
|
+
### ⑤ Operations core: host / compatibility / patch inventory / evidence
|
|
32
|
+
`dsh-drydock-doctor` answers "which host am I on, was it reviewed, which local patches must be replayed after an upgrade"; install/update passes a **reviewed-host gate** (unverified hosts refused; `DSH_DRYDOCK_FORCE_HOST=1` forces with an audit line); `dsh-drydock-verify` emits machine-readable evidence valid for **30 days** (failures emit fail evidence too). → [docs/兼容门禁-reviewed-hosts.md](docs/兼容门禁-reviewed-hosts.md) · [schema/README.md](schema/README.md)
|
|
30
33
|
|
|
31
34
|
## Install (30 seconds)
|
|
32
35
|
|
|
33
36
|
```sh
|
|
34
|
-
#
|
|
35
|
-
dsh plugin --profile
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
dsh web
|
|
37
|
+
dsh plugin --profile web add dsh-drydock@1.1.4 # web profile (stable = npm latest); after 24 h you may omit the version
|
|
38
|
+
dsh plugin --profile desktop add dsh-drydock@desktop # DSH Desktop: start it once, fully quit, use its own CLI, reopen
|
|
39
|
+
dsh plugin --profile web add ./dsh-drydock-<version>.tgz # offline tgz (GitHub Release or `npm pack`)
|
|
40
|
+
dsh plugin --profile web add dsh-drydock@1.1.3 # roll back to the previous stable release
|
|
41
|
+
dsh web # restart to apply (client bundles load at engine startup)
|
|
39
42
|
```
|
|
40
43
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
- **Do not want a profile install?** `npx dsh-drydock` runs the 3081 launcher, `npx dsh-drydock-boot --repair-only` self-checks and repairs, `npx dsh-drydock-rescue` runs the 3082 backup rescue.
|
|
44
|
-
- **Did not install / still the old UI?** ① client bundles load at startup — **restart `dsh web`**; ② pin the version during the 24 h cool-down (or add `dsh-drydock@1.1.3` to `minimumReleaseAgeExclude` in the profile's `pnpm-workspace.yaml`). Full install / update / uninstall / rollback / offline tgz / autostart: [docs/INSTALL.md](docs/INSTALL.md).
|
|
44
|
+
Two entries after install: **3080 sidebar "Plugin manager"** (takes over the built-in plugins page) and the **3081 fallback page** `http://127.0.0.1:3081/plugins`. Set the browser home page to `http://127.0.0.1:3081/` = open → self-check → repair → start.
|
|
45
45
|
|
|
46
|
-
|
|
46
|
+
- **No profile install?** `npx dsh-drydock` (3081 launcher) · `npx dsh-drydock-boot --repair-only` · `npx dsh-drydock-rescue` (3082 backup rescue).
|
|
47
|
+
- **Self-update**: `npx dsh-drydock-update --check` → `--fetch` (download + SRI verify + stage) → `--now` (stop engine → install → health check → restart, rollback on failure) or `--later`. https + SRI only; desktop never self-applies. → [docs/自更新.md](docs/自更新.md)
|
|
48
|
+
- **Not installing / still old UI?** Client bundles load at startup — **restart `dsh web`**; during the cool-down pin the version (or add `dsh-drydock@1.1.4` to `minimumReleaseAgeExclude`). → [docs/INSTALL.md](docs/INSTALL.md)
|
|
47
49
|
|
|
48
|
-
|
|
50
|
+
## Upgrade check (pre-0.9.1 builds)
|
|
49
51
|
|
|
50
|
-
|
|
52
|
+
> ⛔ **`dsh-plugin-manager-pro` before 0.9.1 (incl. `0.9.1-rc2`) is retired**: known supply-chain risk and it crashes on Node < 22.14. npm shows a **strengthened deprecation notice** (not deleted, but do not use).
|
|
51
53
|
|
|
52
54
|
```sh
|
|
53
55
|
dsh plugin --profile web remove dsh-plugin-manager-pro # drop the old package
|
|
54
|
-
dsh plugin --profile web add dsh-drydock@^1.1.
|
|
56
|
+
dsh plugin --profile web add dsh-drydock@^1.1.4 # the only recommended entry
|
|
55
57
|
dsh web # restart to apply
|
|
56
58
|
```
|
|
57
59
|
|
|
58
|
-
`dsh-drydock` is the only recommended
|
|
60
|
+
`dsh-drydock` is the only recommended name; rollback inside 1.0.x uses the same name. Engine must be ≥ 0.1.7-rc.2 (`<0.3.0-0`). See [docs/INSTALL.md](docs/INSTALL.md) · [docs/COMPATIBILITY.md](docs/COMPATIBILITY.md).
|
|
59
61
|
|
|
60
|
-
##
|
|
61
|
-
**1.1.3 closes the self-update chain**: three defects that only show up on a real machine are fixed — ① `--fetch` false failure (the downloader reports `status:"downloaded"` while the old code only accepted `ok/success`); ② **restart always threw** after installing (the worker passed the profile dir positionally to `startEngine`, which takes an options object) and left the engine stopped; ③ the staged tarball lived in the OS temp dir (the "later → tomorrow" path hit ENOENT). Also fixed: rollback on restart failure + engine re-start afterwards; a fresh `running` state is no longer misreported as "applied"; the manager UI no longer shows a pending row for stale/applied states; `--rollback` no longer hardcodes form `web`; the worker uses the real engine port from the PID file.
|
|
62
|
-
**1.1.1 / 1.1.2 are withdrawn** (npm deprecate + unpublish) — use **1.1.3** (or the older 1.1.0). 1.1.3 still contains 1.1.1's operations core and the two 1.1.0 self-update fixes.
|
|
62
|
+
## Desktop (DSH Desktop) support (since 1.1.0)
|
|
63
63
|
|
|
64
|
-
|
|
64
|
+
> The desktop app owns install / start / update / uninstall / crash recovery, so the drydock only does what the official app does **not** cover: **offline read-only diagnostics, self-heal after an official recovery, rebuilding a rescue profile through the official channel** (no page takeover, no autostart, never starts/stops the Host, never writes `node_modules`).
|
|
65
65
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
66
|
+
```sh
|
|
67
|
+
npx dsh-drydock-doctor # ① offline read-only diagnostics (--json for issues)
|
|
68
|
+
npx dsh-drydock-boot --heal-recovery [--apply --confirm web] # ② self-heal after official recovery (dry-run default)
|
|
69
|
+
npx dsh-drydock-boot --rescue-profile # ③ rebuild rescue profile via official channel
|
|
70
|
+
npx dsh-drydock-modules --audit # ④ files that never execute on this host
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
**First-launch host probe + automatic stripping**: the first start probes web / desktop / unknown and persists it; modules that do not belong are **never even `import`ed** (desktop strips `lib/rescue-profile.mjs`, 1,331 lines). → [docs/环境自适应与剥离.md](docs/环境自适应与剥离.md) · ⚠️ covered by fixtures and injected unit tests, but **the real-machine path is not validated yet** — run `dsh-drydock-doctor` first.
|
|
74
|
+
|
|
75
|
+
## 1.1.4 release notes (security fix + performance)
|
|
76
|
+
|
|
77
|
+
- **Dependency**: `zod` `^4.4.3` → **`^4.6.6`** (GHSA-mrhx-c7xc-m3w5 / CVE-2023-54404: `$ZodArray` accumulated one issue per failing element, so an oversized array could exhaust memory).
|
|
78
|
+
- **Second gate**: client-facing array parameters now have business bounds (batch ops `.max(500)`, `setSources` `.max(50)`, evidence `checks` `.max(100)`, `matrix.entries` `.max(10000)`); schemas regenerated with `maxItems`.
|
|
79
|
+
- **Performance**: self-update status read in-process (134–174 ms → 0.1–0.2 ms per plugin-page open); startup snapshot preheat (removes drydock's ~271 ms list/README cold path — page/engine cold start itself remains); progressive section rendering (80 rows first page + show-more/auto-reveal; full 344 rows dropped from ~7,355 to ~1,700 DOM nodes); exactly one `list()` RPC per mount. **Known remaining slow spot (engine-side, not fixed here)**: every switch to the "official bundles" tab still costs ~0.7 s because the engine's `listBundles()` rebuilds a 100+ package inventory per call; see [docs/FAQ.md](docs/FAQ.md) §6 (client cache planned for 1.1.5). See `dev-docs/drydock-1.1.4-性能优化方案.md`.
|
|
80
|
+
- Also includes **1.1.3** (self-update hardening) and the 1.1.1 **operations core**; **1.1.1 / 1.1.2 are withdrawn** — use 1.1.4 or 1.1.0. Details: [docs/releases/1.1.4.md](docs/releases/1.1.4.md) · history: [CHANGELOG.md](CHANGELOG.md)
|
|
71
81
|
|
|
72
82
|
## Entries
|
|
73
83
|
|
|
74
84
|
| Entry | Address | Purpose |
|
|
75
85
|
| --- | --- | --- |
|
|
76
86
|
| Manager (3080) | `http://127.0.0.1:3080` → sidebar "Plugin manager" | Everyday entry: list / install / configure / uninstall / rescue |
|
|
77
|
-
| Fallback page (3081) | `http://127.0.0.1:3081/plugins` |
|
|
78
|
-
| Boot page (3081) | `http://127.0.0.1:3081/` | Open
|
|
87
|
+
| Fallback page (3081) | `http://127.0.0.1:3081/plugins` | Works with the engine down: toggle / update / uninstall / restart |
|
|
88
|
+
| Boot page (3081) | `http://127.0.0.1:3081/` | Open → self-check → repair → start (best as home page) |
|
|
79
89
|
| Rescue page (3081) | `http://127.0.0.1:3081/rescue` | verify / fix / start / stop / status |
|
|
80
90
|
| Rescue button 🛟 | bottom-right of 3080 | Draggable, remembered position; entry when settings are broken |
|
|
81
91
|
|
|
82
|
-
> The engine also serves `/rescue` at
|
|
92
|
+
> The engine also serves `/rescue` at 3080, but it goes through host admission: entering **from inside the app** works; typing it in the address bar is an origin-less top-level navigation and gets rejected.
|
|
93
|
+
|
|
94
|
+
## Everyday use
|
|
83
95
|
|
|
84
|
-
|
|
96
|
+
1. **Toggle**: 3080 sidebar → row switches (core locked); writes `cordis.patch.yml`, **applies after restart**. **Update**: Maintenance → "Check updates" → "Update" (trust model decides the source).
|
|
97
|
+
2. **Uninstall / rescue**: row uninstall → preview + verdict → backup → execute → verify, automatic rollback (Operations tab undoes the last operations); rescue commands and exit codes in [docs/RESCUE.md](docs/RESCUE.md).
|
|
85
98
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
99
|
+
## What it manages / does not
|
|
100
|
+
|
|
101
|
+
| Scenario | Who handles it |
|
|
102
|
+
| --- | --- |
|
|
103
|
+
| Finding plugins, browsing markets, one-click installs | The official page / markets — the drydock **does not build a catalog** |
|
|
104
|
+
| A broken install / too many plugins / engine down | **The drydock**: transactional uninstall + undo (last 20), scenarios, independent 3081 / 3082 rescue |
|
|
105
|
+
| Backup / WebDAV / themes / static scanning | Not done here |
|
|
106
|
+
|
|
107
|
+
## When something breaks
|
|
108
|
+
|
|
109
|
+
| Symptom | Where to go |
|
|
110
|
+
| --- | --- |
|
|
111
|
+
| Engine runs but 3080 UI misbehaves | 🛟 rescue button at 3080 bottom-right, or `/rescue` from inside the app |
|
|
112
|
+
| Engine down, 3080 unreachable | `http://127.0.0.1:3081/`: self-check → repair → start |
|
|
113
|
+
| A plugin disabled the UI | `http://127.0.0.1:3081/plugins` toggles it without the engine |
|
|
114
|
+
| A plugin crashes the engine | 3081 `/plugins` → health verdict → disable or uninstall |
|
|
115
|
+
| Uninstall blocked by a running engine / remove launcher | Refuses to force-delete (disable → restart → retry) · `npx dsh-drydock --uninstall` |
|
|
116
|
+
| Upgrade left local patches behind | `npx dsh-drydock-upgrade --profile web` prints the list (**never writes**) |
|
|
117
|
+
|
|
118
|
+
## Environment and ports
|
|
119
|
+
|
|
120
|
+
- **Platform / Node**: Windows 10/11 · macOS · Linux (autostart is Windows-only); Node `>=22.12.0` (use 24.x). **Engine**: DSH `dsh` ≥ `0.1.7-rc.2` (`<0.3.0-0`) plus `pnpm`.
|
|
121
|
+
- **Ports** (loopback only): **3080** engine · **3081** launcher (boot / fallback / rescue) · **3082** backup rescue · **4081** supervisor lock (3081 + 1000).
|
|
90
122
|
|
|
91
123
|
Details: [docs/COMPATIBILITY.md](docs/COMPATIBILITY.md).
|
|
92
124
|
|
|
93
125
|
## Docs
|
|
94
126
|
|
|
95
|
-
|
|
127
|
+
Detailed docs are Chinese-first; this page is the English entry. Index: [docs/README.md](docs/README.md).
|
|
96
128
|
|
|
97
129
|
| Doc | Content |
|
|
98
130
|
| --- | --- |
|
|
99
|
-
| [docs/INSTALL.md](docs/INSTALL.md) | Install / update / uninstall / rollback / offline tgz /
|
|
100
|
-
| [docs/
|
|
101
|
-
| [docs/
|
|
102
|
-
| [docs
|
|
103
|
-
| [docs/
|
|
104
|
-
| [docs/
|
|
105
|
-
| [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) | Three-process architecture, slot contract, sidecar fields, uninstall transaction |
|
|
106
|
-
| [docs/LAUNCHER.md](docs/LAUNCHER.md) | All CLI commands and exit codes, `--uninstall` loop, write-endpoint guards |
|
|
107
|
-
| [docs/宿主描述与桌面消歧.md](docs/宿主描述与桌面消歧.md) | Host descriptor, official desktop vs community client (read-only), 1.1.1 |
|
|
108
|
-
| [docs/兼容门禁-reviewed-hosts.md](docs/兼容门禁-reviewed-hosts.md) | Reviewed-host table, install/update gate (30-day expiry), force + audit |
|
|
109
|
-
| [docs/补丁清点与升级.md](docs/补丁清点与升级.md) | Patch inventory and replay checklist after engine upgrades (read-only) |
|
|
110
|
-
| [schema/README.md](schema/README.md) | `evidence-v1` / `matrix-v1` / `badge-v1` schemas and generators |
|
|
111
|
-
| [CHANGELOG.md](CHANGELOG.md) | Version history (generated) |
|
|
112
|
-
| [docs/releases/](docs/releases/) | Per-release notes ([1.1.3](docs/releases/1.1.3.md)) |
|
|
113
|
-
| [docs/README-full.md](docs/README-full.md) | v0.9.1-era full archive — **not the current manual** |
|
|
131
|
+
| [docs/INSTALL.md](docs/INSTALL.md) · [docs/USAGE.md](docs/USAGE.md) | Install / update / uninstall / rollback / offline tgz / cool-down / ports · carriers, tabs, transactional uninstall, scenarios, market |
|
|
132
|
+
| [docs/SECURITY.md](docs/SECURITY.md) · [docs/RESCUE.md](docs/RESCUE.md) | Trust model, provenance, guards, admission · rescue toolchain, 3081 API, 3082 |
|
|
133
|
+
| [docs/COMPATIBILITY.md](docs/COMPATIBILITY.md) · [docs/FAQ.md](docs/FAQ.md) · [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) · [docs/LAUNCHER.md](docs/LAUNCHER.md) | Requirements and matrix · FAQ · architecture and sidecars · CLI commands and exit codes |
|
|
134
|
+
| [docs/宿主描述与桌面消歧.md](docs/宿主描述与桌面消歧.md) · [docs/兼容门禁-reviewed-hosts.md](docs/兼容门禁-reviewed-hosts.md) | Host descriptor (official vs community client) · reviewed-host gate (30-day expiry) |
|
|
135
|
+
| [docs/补丁清点与升级.md](docs/补丁清点与升级.md) · [schema/README.md](schema/README.md) | Patch inventory and replay checklist · evidence / matrix / badge schemas |
|
|
136
|
+
| [CHANGELOG.md](CHANGELOG.md) · [docs/releases/](docs/releases/) · [docs/archive/README-v0.9.1-full.md](docs/archive/README-v0.9.1-full.md) | Version history · per-release notes ([1.1.4](docs/releases/1.1.4.md)) · v0.9.1 archive (not current) |
|
|
114
137
|
|
|
115
138
|
## License
|
|
116
139
|
|
|
117
|
-
MIT.
|
|
118
|
-
|
|
119
|
-
Chinese (main) documentation: [README.md](README.md).
|
|
140
|
+
MIT. Patch persistence is inspired by [hrhgit/deepseek-harness-plugin-manager](https://github.com/hrhgit/deepseek-harness-plugin-manager) (MIT). 中文(主文档):[README.md](README.md).
|
package/README.md
CHANGED
|
@@ -11,11 +11,11 @@
|
|
|
11
11
|
|
|
12
12
|
> 社区/本地插件,非 DSH 官方包。npm:`dsh-drydock`(原名 `dsh-plugin-manager-pro`,旧包已挂弃用提示、不删包,仅保留供历史版本安装)· GitHub:[nonentity303/dsh-drydock](https://github.com/nonentity303/dsh-drydock) · 跨平台(Windows / macOS / Linux)
|
|
13
13
|
>
|
|
14
|
-
> **本页对应版本:1.1.
|
|
14
|
+
> **本页对应版本:1.1.4**(本文档随 master 更新)。**以徽章为准**:上面三个徽章是**实时**的 `latest` / `desktop` / `next` 通道版本 —— 如果你是在 npm 页面或第三方目录(ADP 等)看到这份文档的**快照**,那里的文字可能滞后,版本与安装命令请以徽章、`npm view dsh-drydock dist-tags` 或 <https://github.com/nonentity303/dsh-drydock/blob/master/status.json> 为准。
|
|
15
15
|
> ⚠️ 刚发布的版本会被 pnpm 的 **24 小时冷静期**(`minimumReleaseAge`)挡住:装不到或装完还是旧版时,**显式写版本号**(见下方安装)。
|
|
16
16
|
> 版本与通道口径见 [docs/版本与轨道.md](docs/版本与轨道.md):`-desktop.N` = 桌面通道、`-rc.N` = 网页预发布、无后缀 = 正式版。
|
|
17
17
|
|
|
18
|
-
##
|
|
18
|
+
## 五个主打特色
|
|
19
19
|
|
|
20
20
|
### ① 独立救援工具链:引擎挂了还能救
|
|
21
21
|
3081 启动器(`/` 打开即自检启动、`/plugins` 兜底管理页、`/rescue` 救援页)与 3082 备份救援守护跑在**独立进程、独立端口**,不依赖 Cordis 运行时;`verify / fix / start / stop / status` 带明确退出码(0 就绪 / 1 启动失败 / 2 修复未完成),可被外部脚本调用。→ [docs/RESCUE.md](docs/RESCUE.md)
|
|
@@ -29,14 +29,14 @@
|
|
|
29
29
|
### ④ 3081 兜底页 + 引擎外灾看门狗
|
|
30
30
|
引擎挂了也能在 `http://127.0.0.1:3081/plugins` 启停 / 更新 / 卸载 / 体检 / 重启引擎;**常驻守护同时盯着引擎健康**:连续 2 次不健康就自动拉起(与「重启引擎」同一条直达路径),启动器自己卡死也会被回收重拉;你点了「停止引擎」它就不动手。全中文界面、深浅主题自动跟随系统偏好;Windows / macOS / Linux 全平台(开机自启管理目前为 Windows)。→ [docs/USAGE.md](docs/USAGE.md)
|
|
31
31
|
|
|
32
|
-
### ⑤ 运维内核:宿主 / 兼容 / 补丁 /
|
|
32
|
+
### ⑤ 运维内核:宿主 / 兼容 / 补丁 / 证据
|
|
33
33
|
`dsh-drydock-doctor` 现在能回答「我在什么宿主上、这个宿主复核过没有、升级后哪些本地补丁需要重放」;装/更新先过**复核表门禁**(未验证宿主默认拒绝,`DSH_DRYDOCK_FORCE_HOST=1` 强制并留审计);`dsh-drydock-verify` 产出带 30 天有效期的机器可读证据(失败也产证据)。→ [docs/兼容门禁-reviewed-hosts.md](docs/兼容门禁-reviewed-hosts.md) · [docs/补丁清点与升级.md](docs/补丁清点与升级.md) · [schema/README.md](schema/README.md)
|
|
34
34
|
|
|
35
35
|
## 安装(30 秒)
|
|
36
36
|
|
|
37
37
|
```sh
|
|
38
38
|
# 网页版(正式版通道,= npm latest)
|
|
39
|
-
dsh plugin --profile web add dsh-drydock@1.1.
|
|
39
|
+
dsh plugin --profile web add dsh-drydock@1.1.4
|
|
40
40
|
# 发版满 24 小时后,也可以不带版本号
|
|
41
41
|
dsh plugin --profile web add dsh-drydock
|
|
42
42
|
|
|
@@ -48,8 +48,8 @@ dsh plugin --profile desktop add dsh-drydock@desktop
|
|
|
48
48
|
# 离线 tgz(GitHub Release 页下载,或 npm pack 自建)
|
|
49
49
|
dsh plugin --profile web add ./dsh-drydock-<版本>.tgz
|
|
50
50
|
|
|
51
|
-
#
|
|
52
|
-
dsh plugin --profile web add dsh-drydock@1.
|
|
51
|
+
# 回退上一个发布版(1.1.x 之间回退走同一包名)
|
|
52
|
+
dsh plugin --profile web add dsh-drydock@1.1.3
|
|
53
53
|
|
|
54
54
|
# 重启 web 生效(客户端 bundle 在引擎启动时加载)
|
|
55
55
|
dsh web
|
|
@@ -59,7 +59,7 @@ dsh web
|
|
|
59
59
|
|
|
60
60
|
- **不想装进 profile?** `npx dsh-drydock` 起 3081 启动器、`npx dsh-drydock-boot --repair-only` 命令行自检 + 修复、`npx dsh-drydock-rescue` 起 3082 备份救援——都无需安装。
|
|
61
61
|
- **它自己怎么升级?** `npx dsh-drydock-update --check` 查、`--fetch` 校验暂存、`--now` 现在装(停引擎→装→健康检查→重启,失败自动回滚)、`--later` 稍后(下次启动再提示)。只认 https + SRI 摘要,桌面形态不自动装。→ [docs/自更新.md](docs/自更新.md)
|
|
62
|
-
- **装不到 / 装完还是旧版?** ① 客户端 bundle 只在引擎启动时加载,**必须重启 `dsh web`**;② 24 小时冷静期内务必写显式版本号(或把 `dsh-drydock@1.1.
|
|
62
|
+
- **装不到 / 装完还是旧版?** ① 客户端 bundle 只在引擎启动时加载,**必须重启 `dsh web`**;② 24 小时冷静期内务必写显式版本号(或把 `dsh-drydock@1.1.4` 加入 profile `pnpm-workspace.yaml` 的 `minimumReleaseAgeExclude`)。完整安装 / 更新 / 卸载 / 回退 / 离线 tgz / 开机自启见 [docs/INSTALL.md](docs/INSTALL.md)。
|
|
63
63
|
|
|
64
64
|
## 升级自查(0.9.1 之前的老用户必看)
|
|
65
65
|
|
|
@@ -69,11 +69,11 @@ dsh web
|
|
|
69
69
|
|
|
70
70
|
```sh
|
|
71
71
|
dsh plugin --profile web remove dsh-plugin-manager-pro # 移除旧包(保留 profile 备份)
|
|
72
|
-
dsh plugin --profile web add dsh-drydock@^1.1.
|
|
72
|
+
dsh plugin --profile web add dsh-drydock@^1.1.4 # 安装唯一推荐入口
|
|
73
73
|
dsh web # 重启生效
|
|
74
74
|
```
|
|
75
75
|
|
|
76
|
-
新包名 `dsh-drydock` 是唯一推荐入口;1.
|
|
76
|
+
新包名 `dsh-drydock` 是唯一推荐入口;1.1.x 之间回退用同一包名(如 `dsh-drydock@1.1.3`)。引擎要求 ≥ 0.1.7-rc.2,更老的引擎请留在历史版本。详见 [docs/INSTALL.md](docs/INSTALL.md) 与 [docs/COMPATIBILITY.md](docs/COMPATIBILITY.md)。
|
|
77
77
|
|
|
78
78
|
## 桌面版(DSH Desktop)支持(1.1.0 新增)
|
|
79
79
|
|
|
@@ -92,11 +92,14 @@ npx dsh-drydock-modules --audit # ④ 本环境永
|
|
|
92
92
|
→ [docs/环境自适应与剥离.md](docs/环境自适应与剥离.md) · [docs/桌面版移植-1.1.0设计.md](docs/桌面版移植-1.1.0设计.md)
|
|
93
93
|
> ⚠️ 桌面能力有 fixture + 注入式单测覆盖,但**真机链路未验收**:首次请先跑 `dsh-drydock-doctor`。
|
|
94
94
|
|
|
95
|
-
## 1.1.
|
|
95
|
+
## 1.1.4 发布说明(安全修复 + 性能收口 + 自更新收口 + 运维内核)
|
|
96
|
+
|
|
97
|
+
- **安全修复**:`zod` 升到 `^4.6.6`(GHSA-mrhx-c7xc-m3w5 / CVE-2023-54404:数组校验逐元素累积 issue,超大数组可耗尽内存)+ 所有对外入参数组加业务上界(批量 500 / 来源 50 / 证据 checks 100 / 矩阵 10000)。
|
|
98
|
+
- **性能收口(本版新增)**:① 自更新状态改**进程内读取**(不再每次开「全部插件」页 spawn 一个 node CLI,实测 **134–174ms → 0.1–0.2ms**);② 引擎启动后**后台预热**一次插件快照(消掉 drydock 列表/简介的 ~271ms 冷路径;**页面/引擎本身的首次冷启动仍在**);③ 插件列表**分区渐进渲染**(每区首屏 80 行,「显示更多」/滚动自动续页,344 行全展开的 DOM 从 7,355 降到约 1,700);④ 页面挂载只发一次 `list()` RPC(补了回归断言)。**已知慢点(非本版可控)**:「官方内置」页每次切过去仍要 ~0.7s——引擎 `listBundles()` 每次重建 100+ 包清单,1.1.5 计划客户端缓存 + 预取(见 [docs/FAQ.md](docs/FAQ.md) §六)。方案与实测见 `dev-docs/drydock-1.1.4-性能优化方案.md`。
|
|
96
99
|
- **1.1.3 = 自更新收口**:修完三个真机上会出事的缺陷 —— ① `--fetch` 假失败(下载器成功词是 `downloaded`,旧代码只认 `ok/success`);② 装完**重启必抛错**、引擎停着(worker 把目录按位置传给只收选项对象的 `startEngine`);③ 暂存文件留在系统临时目录(「稍后」再装会 ENOENT)。另修:重启抛错也回滚并重新拉起引擎、`running` 不再被误判「已完成」、管理台陈旧态不再误报、`--rollback` 不再写死 web 形态、worker 端口取 PID 文件里的真实值。
|
|
97
|
-
- **已撤回 1.1.1 / 1.1.2**(npm deprecate + unpublish):它们带上面 ①②③ 缺陷,请用 **1.1.
|
|
98
|
-
- 验证:`.dsh-test-engine`
|
|
99
|
-
- 逐条与测试证据:[docs/releases/1.1.
|
|
100
|
+
- **已撤回 1.1.1 / 1.1.2**(npm deprecate + unpublish):它们带上面 ①②③ 缺陷,请用 **1.1.4**(或更早的 1.1.0)。本版仍包含 1.1.1 的**运维内核**(宿主描述 / 兼容门禁 / 补丁清点 / 证据生成器)与 1.1.0 的两处自更新修复。
|
|
101
|
+
- 验证:`.dsh-test-engine` 隔离引擎(33080)真装真跑 1.1.4(服务端路由 + 客户端 bundle 在位);`npm test`(含 build)全绿;性能基准 `node tools/dev/bench-pages.mjs` 可复跑。
|
|
102
|
+
- 逐条与测试证据:[docs/releases/1.1.4.md](docs/releases/1.1.4.md) · 历史版本:[CHANGELOG.md](CHANGELOG.md)
|
|
100
103
|
|
|
101
104
|
## 入口速查
|
|
102
105
|
|
|
@@ -167,7 +170,7 @@ npx dsh-drydock-modules --audit # ④ 本环境永
|
|
|
167
170
|
| [docs/宿主描述与桌面消歧.md](docs/宿主描述与桌面消歧.md) 等 | **1.1.1 运维内核**:宿主描述与[桌面消歧](docs/宿主描述与桌面消歧.md) · [兼容门禁](docs/兼容门禁-reviewed-hosts.md) · [补丁清点](docs/补丁清点与升级.md) · [证据 schema](schema/README.md) |
|
|
168
171
|
| [CHANGELOG.md](CHANGELOG.md) | 版本历史(脚本生成) |
|
|
169
172
|
| [docs/releases/](docs/releases/) | 每版发布说明(本页对应 [1.1.0-desktop.3](docs/releases/1.1.0-desktop.3.md)) |
|
|
170
|
-
| [docs/README-full.md](docs/README-full.md) |
|
|
173
|
+
| [docs/archive/README-v0.9.1-full.md](docs/archive/README-v0.9.1-full.md) | v0.9.1 时代的**归档全文**(能力对比 / 兼容矩阵),**非当前手册**,仅作历史参考 |
|
|
171
174
|
|
|
172
175
|
## 许可证
|
|
173
176
|
|
package/bin/drydock-update.mjs
CHANGED
|
@@ -35,6 +35,7 @@ import {
|
|
|
35
35
|
isStaleState,
|
|
36
36
|
localCandidate,
|
|
37
37
|
promptText,
|
|
38
|
+
readSelfUpdateStatus,
|
|
38
39
|
readState,
|
|
39
40
|
resolveDshHome,
|
|
40
41
|
spawnDetachedWorker,
|
|
@@ -184,21 +185,12 @@ async function main(argv = process.argv.slice(2)) {
|
|
|
184
185
|
|
|
185
186
|
// ── --status(只读)──────────────────────────────────────
|
|
186
187
|
if (args.status) {
|
|
187
|
-
|
|
188
|
+
// 1.1.4(A1):状态读取逻辑收到 lib/self-update.mjs —— CLI 与 host 的进程内读取共用同一份实现。
|
|
189
|
+
const status = readSelfUpdateStatus({ dshHome, currentVersion, form });
|
|
188
190
|
out(
|
|
189
191
|
args.json,
|
|
190
|
-
{
|
|
191
|
-
|
|
192
|
-
profileDir,
|
|
193
|
-
form,
|
|
194
|
-
formSource,
|
|
195
|
-
currentVersion,
|
|
196
|
-
channel: distTagForForm(form),
|
|
197
|
-
canApply: canSelfApply(form),
|
|
198
|
-
state,
|
|
199
|
-
prompt: promptText(state, { canApply: canSelfApply(state?.form ?? form) })
|
|
200
|
-
},
|
|
201
|
-
statusText(state)
|
|
192
|
+
{ ...status, profileDir, formSource },
|
|
193
|
+
statusText(status.state)
|
|
202
194
|
);
|
|
203
195
|
return 0;
|
|
204
196
|
}
|