Skip to content

Commit 67ead60

Browse files
committed
feat(nono): add droid-local profile
Sandbox the Droid CLI the same way the other harnesses are, as a thin delta over a base profile. The Nono registry ships no nolabs-ai/droid pack, so droid.json.tmpl stands in for one locally, mirroring the structure the official agent packs use. Delete it and repoint droid-local if a pack ever ships. Droid-specific grants beyond the shared local delta: - ~/.factory holds the entire config tree, including the auth keyring - $TMPDIR needs read as well as write, because the Execute tool creates /tmp/droid-terminal-XXXXXX and reads back from it while Nono leaves /tmp write-only - ~/.config/agents/AGENTS.md is granted explicitly, since Landlock resolves the ~/.agents/AGENTS.md symlink to its target Also symlinks ~/.agents/AGENTS.md so Droid picks up the global agent instructions, which it was the only harness missing.
1 parent 456f480 commit 67ead60

4 files changed

Lines changed: 96 additions & 0 deletions

File tree

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{{ .chezmoi.homeDir }}/.config/agents/AGENTS.md

‎home/private_dot_config/fish/conf.d/abbrs.fish‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,8 @@ abbr -a nncx "nono-with-local-path wrap --profile codex-local --allow-cwd -- cod
191191
abbr -a nncxc "nono-with-local-path wrap --profile codex-local --allow-cwd -- codex resume --last"
192192
abbr -a nnp nono-pi
193193
abbr -a nnpc "nono-pi --continue"
194+
abbr -a nnd "nono-with-local-path wrap --profile droid-local --allow-cwd -- droid"
195+
abbr -a nndc "nono-with-local-path wrap --profile droid-local --allow-cwd -- droid --resume"
194196
abbr -a o open
195197
abbr -a oc opencode
196198
abbr -a occ "opencode --continue"
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{{- /* extends "droid" is the local base profile alongside this one, not a
2+
registry pack: the Nono registry has no nolabs-ai/droid pack. Droid
3+
spawns and signals its own children (droid exec subagents, background
4+
processes), so it needs signal_mode allow_same_sandbox via "security".
5+
~/.agents/AGENTS.md is a symlink, so reading it needs its target granted
6+
on top of the base profile's ~/.agents read. */ -}}
7+
{{- includeTemplate "nono-local-profile" (dict
8+
"ctx" .
9+
"extends" "droid"
10+
"name" "droid-local"
11+
"version" "0.1.0"
12+
"description" "Droid with local mise runtime access and external git include access"
13+
"security" true
14+
"extraReadFile" (list
15+
(joinPath .chezmoi.homeDir ".config/agents/AGENTS.md")
16+
)
17+
) -}}
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
{{- /* Local stand-in for a registry-managed base pack: the Nono registry ships
2+
no nolabs-ai/droid pack (`nono search droid` finds nothing), so this
3+
mirrors the structure of the official agent packs to keep droid-local a
4+
thin delta. Delete this file and repoint droid-local at the pack if one
5+
ever ships.
6+
7+
- ~/.factory is droid's entire config tree: settings.json, the auth
8+
keyring, sessions, logs, droids, snapshots, specs, bin/rg, certs.
9+
- ~/.agents is where droid discovers personal skills and AGENTS.md.
10+
- $TMPDIR needs read as well as write: droid's Execute tool creates
11+
/tmp/droid-terminal-XXXXXX and reads back from it, while Nono's
12+
system_write_linux group leaves /tmp write-only. */ -}}
13+
{
14+
"$schema": "https://raw.githubusercontent.com/nolabs-ai/nono/refs/heads/main/crates/nono-cli/data/nono-profile.schema.json",
15+
"extends": "default",
16+
"meta": {
17+
"name": "droid",
18+
"version": "0.1.0",
19+
"description": "Factory Droid CLI agent (local base profile)"
20+
},
21+
"groups": {
22+
"include": [
23+
"node_runtime",
24+
"rust_runtime",
25+
"python_runtime",
26+
{ "name": "user_caches_macos", "when": "macos" },
27+
{ "name": "user_caches_linux", "when": "linux" },
28+
{ "name": "linux_sysfs_read", "when": "linux" },
29+
"nix_runtime",
30+
"git_config",
31+
"unlink_protection"
32+
]
33+
},
34+
"security": {
35+
"signal_mode": "isolated",
36+
"capability_elevation": false
37+
},
38+
"filesystem": {
39+
"allow": [
40+
"{{ joinPath .chezmoi.homeDir ".factory" }}",
41+
"{{ joinPath .chezmoi.homeDir ".config/nono/profile-drafts" }}",
42+
"$TMPDIR"
43+
],
44+
"read": [
45+
"{{ joinPath .chezmoi.homeDir ".agents" }}",
46+
"{{ joinPath .chezmoi.homeDir ".config/nono/packages" }}",
47+
"{{ joinPath .chezmoi.homeDir ".config/nono/profiles" }}"
48+
]
49+
},
50+
"network": {
51+
"block": false
52+
},
53+
"workdir": {
54+
"access": "readwrite"
55+
},
56+
"open_urls": {
57+
"allow_origins": [
58+
"https://app.factory.ai",
59+
"https://factory.ai",
60+
"https://github.com"
61+
],
62+
"allow_localhost": true
63+
},
64+
"allow_launch_services": true,
65+
"undo": {
66+
"exclude_patterns": [
67+
"node_modules",
68+
".next",
69+
"__pycache__",
70+
"target",
71+
".factory"
72+
],
73+
"exclude_globs": ["*.tmp.[0-9]*.[0-9]*"]
74+
},
75+
"interactive": true
76+
}

0 commit comments

Comments
 (0)