dsh-wsl-gpufix
Run the following command in DeepSeek Harness:
dsh plugin install Jumqyc/dsh-wsp-gpufix
Paste the following prompt into your AI chat to install this plugin:
Run dsh plugin install Jumqyc/dsh-wsp-gpufix in the DeepSeek Harness terminal to install; the source lives at https://github.com/Jumqyc/dsh-wsp-gpufix. Source: https://github.com/Jumqyc/dsh-wsl-gpufix
About this plugin
When running DSH on WSL2, the Landlock sandbox hard-codes a device whitelist that denies read-write access to /dev/dxg and /proc. The result is simple: torch.cuda.is_available() always returns False and CUDA initialization fails with error 100 or 304. This plugin exists to close exactly that gap.
It hooks the public sandbox.confine() seam via the Cordis host-composition mechanism and appends --rw /dev/dxg and --rw /proc to the Landlock argument list before the session starts. The confined bash agent can then open the GPU device and complete CUDA thread registration without any vendor file being patched, the sandbox being disabled, or the approval policy being altered. Unloading the plugin restores the original method immediately.
If you rely on DSH for multi-model inference on WSL2, need PyTorch GPU acceleration, and want to keep the isolation guarantees that the sandbox provides, this plugin offers a lightweight, reversible way to grant just the two device paths that CUDA requires.
Use Cases
- torch.cuda.is_available() keeps returning False inside a confined DSH bash session on WSL2
- nvidia-smi reports GPU access blocked by the operating system within the sandbox
- CUDA initialization fails with error 100 or 304 while the GPU works fine in an unsandboxed terminal
Best For
- Developers relying on DSH for PyTorch GPU inference on WSL2
- DSH users who want to keep Landlock sandbox isolation while accessing GPU devices
- End users hitting CUDA device denial in the sandbox without wanting to hand-craft Landlock configs
Related Plugins
A unified suite combining hot runtime injection, task-aware thinking-mode routing, and a graded session protocol with red-team gates to sustain model diligence across long-horizon inference.
ModLens is a vision plugin for DeepSeek Harness that gives text-only models sight by reading images pasted directly into chat, with zero-config setup and multiple vision engines.
On-demand vision for text-only DeepSeek Harness agents: built-in free keyless vision chain and 14 vision tools, routing image turns as tool calls to vision models with pixel fidelity, no Python needed, one-command install.
Give text-only models in DeepSeek Harness eyes, enabling image Q&A, long-screenshot OCR, UI restoration, and GUI visual tasks.