Preface¶
When developing agents in DeepSeek Harness (DSH), a common scenario is: code and commands run on another machine or another environment, and the remote side exposes directories as MCP tools (read, apply_patch, exec_command, etc.) through a DevSpace-like executor, while the local DSH still needs an independent workspace, session cwd, and manageable MCP endpoints. If each remote node is configured separately and remote directories are disconnected from the local Workspace, maintenance becomes difficult as nodes increase, and file round-trips easily become confused with the model of “the project itself is on the remote, the local is just a mirror.”
Below is the community plugin dsh-devspace (maintainer lifecoder1988), which centrally manages multiple DevSpace nodes within DSH and “adopts” selected remote directories as local mirror workspaces. Together with bidirectional file transfer tools, it lets sessions hang under a real Workspace while remote operations still go through the corresponding node’s MCP tools.
What Is This¶
dsh-devspace is a workflow-class plugin for DSH: it manages N DevSpace nodes within a single plugin (each node corresponds to one MCP endpoint), supports mapping remote directories to local mirror Workspaces, and transfers files between remote and local mirrors via devspace_pull / devspace_push. The plugin package name is @local/dsh-devspace, licensed under MIT, with the current repository version 1.0.0.
The remote remains remote: remote code and commands are only invoked via that node’s mcp__<node_name>__<tool>, and the local mirror directory does not auto-sync.
Core Features¶
Node Management¶
One node equals one MCP endpoint. Node configuration is persisted in $DSH_HOME/devspace-nodes.json (can be overridden by the config option nodesFile). When enabling nodes, hot-mounting happens through @deepseek-ai/dsh-mcp-client, no DSH restart is needed; tool names look like mcp__<node_name>__<tool>. Adding, deleting, modifying, enabling, disabling, and reconnecting nodes can be done via the settings page or the model tool devspace_admin.
Remote Directory → Local Mirror Workspace¶
In the workspace selector, use “Add Remote…” (requires an upstream client patch, see below), browse the remote directory tree and select a directory. The plugin will:
- Call
open_workspaceon that directory remotely to obtain the remoteworkspace_id; - Create
<mirrorRoot>/<node_name>/<path>locally (default~/DevSpace/...), and write anAGENTS.mdexplaining that the project itself is on the remote and the purpose of the local directory; - Register this local directory as a real DSH Workspace, visible in the sidebar
Workspaces, with session ownership andcwdpointing to the mirror directory.
Mirror relationships are recorded in $DSH_HOME/devspace-mirrors.json (default path, configurable via mirrorsFile).
File Transfer¶
- devspace_pull: remote file → local mirror (can specify the destination path, defaults to the same relative path within the mirror);
- devspace_push: local → remote (can specify the remote destination, defaults to the relative path within the mirror).
Transfers are binary-safe and chunked, with bidirectional integrity verification. Due to remote Express request body limits of about 100 KB, Windows command line limits of about 32 KB, etc., the default download chunk is 48 KiB (pullChunkBytes) and the upload chunk is 16 KiB (pushChunkBytes); if the file length after writing does not match the bytes sent, the entire file is re-transferred (up to 3 times).
Model Tools and Skills¶
| Tool | Description |
|---|---|
devspace_admin |
Nodes: status / add / update / remove / enable / disable / retry; Mirrors: mirrors / open / unmirror / mirrorRoot |
devspace_target |
Returns the remote target (node, remote path, workspace_id, local mirror directory) based on the current session cwd; returns null when there is no target |
devspace_pull |
Remote → Local |
devspace_push |
Local → Remote |
The plugin also publishes a global skill devspace-nodes, rendered from the current node list, instructing the model on the difference between remote and local mirrors and the invocation order.
UI and Scope¶
The plugin injects UI into multiple Cordis slots: the settings page section devspace, the workspace menu “Add Remote…”, the remote directory dialog, and sidebar badges and session chips for mirror workspaces. The “Remote Nodes (DevSpace)” section in the MCP / skills / project keys panel converges by current workspace: when the current workspace is a mirror, only the corresponding node is shown; when not a mirror, the entire section is hidden, and the Host does not issue irrelevant remote commands.
Installation and Activation¶
It is recommended to install via pnpm under the corresponding profile directory (this writes into the composition together with cordis.patch.yml):
cd "$DSH_HOME/profiles/<profile>"
pnpm add github:lifecoder1988/dsh-devspace
Alternatively, manually add to the profile’s cordis.patch.yml:
- insert:
- id: devspace
name: '@local/dsh-devspace'
After installation, if the change involves the host side, you need to restart DSH; if only the client side, just refresh the page.
The plugin runs with the current DSH process permissions. Before installation, please review the GitHub repository source code and MIT license yourself.
Upstream Client Patch (Optional)¶
The full UI (workspace menu “Add Remote…”, list node icons, Hero chip node names) depends on two upstream patches. You need to apply the patches in the DSH checkout directory and rebuild the client packages:
git apply /path/to/dsh-devspace/patches/upstream-workspace-action-slot.patch
git apply /path/to/dsh-devspace/patches/upstream-workspace-remote-badge.patch
pnpm --filter @deepseek-ai/dsh-client-ui-workspace run bundle
pnpm --filter @deepseek-ai/dsh-client-ui-conversation run bundle
pnpm run build:web
Without the patches, node management, HTTP routes, and model tools still work; only the workspace menu lacks “Add Remote…”, and the list and chips lack remote markers. You can operate via the settings page node management and model tools.
Typical Usage¶
1. Install the Plugin and Restart (or Refresh)¶
Follow the previous section to complete the profile installation and composition integration.
2. Add and Enable DevSpace Nodes¶
In the settings page “DevSpace” section or via devspace_admin’s add / enable, configure the MCP endpoint URL and headers (supports ${VAR} references to avoid plaintext token storage). After enabling, tools appear on the model side as mcp__<node_name>__*.
3. Adopt a Remote Directory as a Local Workspace¶
In the patched client: workspace selector → “Add Remote…” → browse remote directories → confirm. The plugin executes the /devspace/open flow, the local mirror directory appears and is registered as a Workspace.
Without UI patches, you can use devspace_admin’s open or equivalent capabilities (refer to the README and tool schema).
4. Start Sessions Under the Mirror Workspace and Transfer Files¶
The session cwd falls into the mirror directory. Use devspace_target to confirm the remote node and path bound to the current session; call devspace_pull or devspace_push when file synchronization is needed. Remote editing and execution still go through that node’s MCP tools, rather than assuming the local directory is already in real-time sync with the remote.
5. Self-Check (Optional)¶
The repository provides offline self-check scripts:
node test/local-check.mjs # host: node storage, mounting, routes
node test/mirror-check.mjs # mirror flow and bidirectional transfer (built-in simulated remote, 20 assertions)
Configuration Options¶
You can override the following fields in the plugin config (default behavior in parentheses):
config:
dshHome: /path/to/.dsh # default $DSH_HOME or ~/.dsh
nodesFile: …/devspace-nodes.json
mirrorsFile: …/devspace-mirrors.json
mirrorRoot: ~/DevSpace
pullChunkBytes: 49152
pushChunkBytes: 16384
You can also override chunk sizes with transferChunkBytes or per-direction keys.
Host-side behavior changes (such as /remote early return by workspace, title migration rules) require restarting DSH; client-side marker polling etc. only requires a refresh.
Use Cases and Notes¶
Suitable for: You are already using DevSpace MCP on multiple machines and want to uniformly mount nodes within DSH; you need to register remote project directories as formal Workspaces and store downloaded data, pending upload artifacts, or local scripts in local mirror directories; you need controlled, verifiable file movement between remote and local mirrors.
Notes:
- The mirror directory is not an auto-sync disk; remote truth still operates via MCP.
- The full “Add Remote…” and badge UI depend on applying upstream patches yourself and rebuilding the web client.
- The plugin and the DSH community catalog (such as the SkillHub plugin page) are part of the community ecosystem and have no official affiliation with DeepSeek / High-Flyer; if catalog information conflicts with the GitHub README, the repository documentation prevails.
Conclusion¶
dsh-devspace consolidates DevSpace’s “multiple MCP endpoints + remote directories + local Workspace” into a single workflow: node hot-mounting, mirror workspace registration, chunked bidirectional transfer, and a settings panel that converges by workspace, making it easy to distinguish local session directories from remote execution surfaces within DSH.
- Plugin catalog page: https://www.skillhub.cn/plugins/lifecoder1988/dsh-devspace
- Source code and detailed documentation: https://github.com/lifecoder1988/dsh-devspace