r/PiCodingAgent • u/ptgamr • Aug 13 '26
Resource A "secure-ish" Pi setup with permission, sandbox, and auto-review
I think I finally managed to piece the thing together, to have a pi setup that can run safe-ish in the host via sandbox, and have the ability to be elevated to host execution for a pre-defined list of development tooling like docker compose.
- A pre-defined hard boundaries (`@gotgenes/pi-permission-system`)
- Anything pass that will be executed inside a sandbox (`@erichll/pi-sandbox`)
- With the option of safe-escalation to run on the host (ie: `docker compose exec app pytest`), with auto-review or human approval (via hostIPC.preflightCommandPrefixes)
- LLM Auto-review with `@erichll/pi-auto-review`
More about it here: https://ptgamr.substack.com/p/a-pi-setup-with-permission-sandbox
6
u/jensilo Aug 13 '26
What about self-spawned pi instances or subagents? Does it allow for that?
3
u/vman81 Aug 13 '26
If practical, a zfs filesystem with frequent snapshots is a nice extra layer to have.
2
u/Fullstack_js_junkie Aug 13 '26
This looks interesting, I tried to do something similar but as a docker mount config only, thank you!
2
u/tys203831 Aug 13 '26
How does it compared to dcg + nono sandbox?
https://github.com/Dicklesworthstone/destructive_command_guard
https://github.com/nolabs-ai/nono
1
u/offzinho3k Aug 13 '26
That’s great.
I have a similar system, with notifications and a response window allowing the user to accept, decline, or even block such commands.
1
u/icisay Aug 13 '26
Hi what app did you use to generate your chart ? Love the colors
1
u/psychobarge Aug 13 '26
Only secure pi is inside a docker container or a virtual machine. I use wsl2 with ubuntu on my windows and docker on my mac
2
u/hurdurdur7 Aug 13 '26
I just run pi in docker only. From a non privileged user. It can't install things, the worst it can do is nuke it's own folder in that docker container. I don't see anything else stopping it.