AI Agent Hub
Back to plugins
🖥️

dsh-service-watchdog

Client Updated 2026.08.26

Run the following command in DeepSeek Harness:

dsh plugin install LucienLL/dsh-service-watchdog

Paste the following prompt into your AI chat to install this plugin:

Run dsh plugin install LucienLL/dsh-service-watchdog in the DeepSeek Harness terminal to install it; the source is available at https://github.com/LucienLL/dsh-service-watchdog .

About this plugin

When the DSH web service crashes or simply needs a restart, the usual workflow - manually killing processes, cleaning up leftovers, and relaunching - is one careless step away from zombie processes or even terminating an unrelated program sharing the same port. There is no built-in self-healing, and the service does not survive a reboot, making daily heavy development feel fragile and overly manual.

dsh-service-watchdog adds a persistent service-control panel to the DSH sidebar. At a glance you see real-time status and uptime; a one-click restart first checks for active sessions, queued messages, and background tasks, pops a secondary confirmation with the exact counts if any exist, then reports a clear success or failure result. A lightweight watchdog process (a few MB) lives independently in the background, automatically relaunching the service after a crash and hot-reloading its own code within 15 seconds of a disk change - no manual process kill or reboot involved. With autostart enabled, the entire monitor, restart, recover, and boot cycle runs silently; restarts use taskkill /T /F to terminate the full process tree and confirm the port is freed before spinning up a new instance, so nothing lingers.

On the security side, the watchdog binds exclusively to 127.0.0.1, rejects cross-origin requests, verifies the target PID maps to node.exe before killing it, and filters sensitive environment variables such as tokens, keys, and secrets when persisting the launch command. It is well suited for developers who lean on DSH heavily every day and want a hands-off service lifecycle, as well as for anyone running DSH long-term on a personal Windows machine without wanting to deploy system-level supervisors like systemd or pm2.

Use Cases

  • DSH web service crashes unexpectedly and the watchdog relaunches it within seconds
  • One-click restart checks active sessions and queued tasks before killing, preventing data loss
  • After a PC reboot, the watchdog and DSH service start automatically without any manual steps

Best For

  • Engineers who work in the DSH environment most of the day
  • Users running DSH long-term on a personal Windows machine
  • Teams or individuals who prefer a lightweight solution over systemd or pm2