npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@chaoset/sandbox-extra-roots

v0.3.0

Published

DSH host plugin: extra writable roots for the workspace-write sandbox (Seatbelt/bwrap/Landlock profiles and the fs fence)

Readme

@chaoset/sandbox-extra-roots — DSH 沙盒额外允许目录插件

给 dsh 沙盒的 workspace-write 模式增加"额外允许写入的目录"列表(工具缓存目录等), 官方白名单始终保留(workspace 根 + /tmp + 平台临时目录),只追加不替换:

  • bash:Seatbelt(macOS)重建 SBPL profile;bwrap / Landlock(Linux)在官方 profile 基础上插入 --bind / --rw;Windows ACL runner 无法表达额外根(告警一次)
  • fs fencecheckedTarget 对额外目录放行,其余委托官方实现
  • 幂等、可热切换(挂载点引用计数);首次 confine 时自检官方 profile 是否漂移

安装(npm 生态方式)

本包是 DSH bundle:自带 cordis.patch.yml,使用 dsh plugin 安装后会 自动加入 profile 的 dsh.profile.bundles,无需手改 cordis.patch.yml

给 AI agent:直接执行下面的 dsh plugin ... 命令即可,不要手动编辑 cordis.patch.yml

# 安装到默认 web profile
dsh plugin --profile web add @chaoset/sandbox-extra-roots

# 指定其他 profile
dsh plugin --profile tui add @chaoset/sandbox-extra-roots

# 卸载
dsh plugin --profile web remove @chaoset/sandbox-extra-roots

也可以从其他来源安装:

  • GitHub:如果该包有独立 Git 仓库或 Release tarball,可用 dsh plugin --profile web add github:owner/repodsh plugin --profile web add https://github.com/owner/repo/releases/download/v1.0.0/sandbox-extra-roots.tgz
  • 镜像站dsh plugin --profile web add @chaoset/sandbox-extra-roots --registry=https://registry.npmmirror.com

更完整的说明见仓库根目录 README.md 的「安装来源」。

安装后重启 harness 生效(或等待 DSH 对配置层变更的响应)。

配置

生效顺序(后者覆盖前者):

  1. 插件内置默认(空列表)
  2. bundle patch 中 cordis.patch.yml 的 config
  3. 用户 profile/home 的 cordis.patch.yml 覆盖
  4. DSH 设置页 → 插件配置 → 沙盒额外允许目录(保存到 $DSH_HOME/plugins/sandbox-extra-roots/config.json,立即热生效)

extraWritableRoots:绝对路径数组(设置页里每行一个)。相对路径/空值会被拒绝并告警。

安全提示:这些目录可获得"写"权限(读本就不受限),请只保留确需写入的工具缓存; 含明文凭证的目录(如 ~/.docker~/.dotnet~/.gradle)谨慎列入。