DeepSeek Harness plugin

dsh-power

Power controls for the DeepSeek Harness Web GUI: shut down or restart DSH from the browser sidebar

Jump to install

Source facts

Repository
jcfung1122/dsh-power
Latest update
Aug 17, 2026
Category
Tools & Capabilities
GitHub stars
0
Format
plugin
Catalog evidence
Upstream dsh.bundle evidence
Evidence path
package.json#dsh.bundle
Checked against
0.1.0-rc.8
Upstream check date
2026-08-20

This evidence comes from the upstream catalog. This site has not installed, run, or security-reviewed the plugin.

Install

Start with a prompt that asks an agent to review the GitHub repository and source. Switch to the command if you want to install it yourself.

Copy this prompt into DSH, Codex, or another agent and ask it to review the GitHub repository and source first.

Do not install or run any commands yet. Read this plugin's GitHub repository, README, and relevant source code. Then answer the questions below clearly and directly so I can decide whether it fits my needs:

1. What is this plugin, and what problem does it solve?
2. Who is it for, and what are its typical use cases?
3. How is it used after installation? Include one minimal example.
4. What known limitations or privacy, security, compatibility, or maintenance risks does it have?
5. Give a clear recommendation: recommend, conditionally recommend, or do not recommend, with reasons.

Distinguish statements documented by the repository, inferences from source code, and unknowns. If evidence is insufficient, say so explicitly. Do not guess or simply repeat the README.

GitHub: https://github.com/jcfung1122/dsh-power
Plugin: dsh-power
Author: jcfung1122

Check the source files

Read the README and other files from this plugin directory before installing.

File explorer4 files
README.en.mdSource · read only
README language

dsh-power

![License](LICENSE) ![DSH](https://github.com/deepseek-ai/deepseek-harness)

English | 中文

A power button for the DeepSeek Harness Web GUI: shut down or restart DSH from the sidebar, right above Settings.

Features

  • 🚫 Never closes the wrong browser window — the page closes itself via window.close(); the host process never kills Chrome.
  • 🧭 Environment-adaptive — no hardcoded path or port. The restart command is rebuilt from the running process, and the reopen URL follows the actual listen port.
  • 🌍 Cross-platform — Windows (windowless wscript helper), macOS (open), Linux (xdg-open).
  • Zero configuration — works immediately after install.

Quick start

Requires a DeepSeek Harness web profile (@deepseek-ai/dsh >= 0.1.0-rc.6).

dsh plugin --profile web add "github:jcfung1122/dsh-power"

Restart the running dsh web, hard-refresh the browser, and the power icon appears above Settings.

Remove:

dsh plugin --profile web remove dsh-power

Usage

Hover the power icon and pick:

![Power button hover menu](screenshot.png)

  • Shut down DSH — closes only this page and stops the service gracefully; other browser windows are unaffected.
  • Restart Web UI — relaunches the service and reopens the page automatically.

Both ask for confirmation first.

Configuration

Usually no configuration is needed. To override, add it to cordis.patch.yml:

- id: power
  config:
    restartWaitMs: 7000     # how long to wait for the old process to release the port (ms)
    restartCommand: ""      # full restart command for supervisor-managed deployments
    reopenUrl: ""           # override the auto-detected reopen URL
KeyDefaultDescription
restartWaitMs7000How long to wait for the old process to release the port before relaunching.
restartCommand(auto)Full restart command; defaults to rebuilding it from the current process.
reopenUrl(auto)Reopen URL; defaults to http://127.0.0.1:<port>.

How it works

The host half registers two loopback-only POST routes: /api/power/shutdown and /api/power/restart. shutdown requests the launcher-provided appExit to exit gracefully; restart rebuilds the launch command from process.argv, reads the reopen URL from the web server port, then detaches a cross-platform helper (Windows uses a windowless VBS to escape the parent job; macOS/Linux use sh + open/xdg-open) and exits. After confirmation, the browser closes this page with window.close().

Privacy & security

  • Both endpoints are exact routes outside the RPC trust boundary; each handler fences itself: POST-only and loopback peer only.
  • No session, prompt, or model data is read.

Development

npm test           # pure JS, no build step; the browser half is also materialized and tested in Node
npm pack --dry-run

The browser half has no build step: it is a hand-written __ModuleLoader__ bundle, and React arrives from the host as a peer.

License

[MIT](LICENSE)