Scripts for setting up a host machine and provisioning isolated microsandbox containers that run pi development agents against a local LLM.
Host Machine ──(microsandbox)──► Sandboxed Dev Agent
│
└──► llama.cpp (external GPU server)
- The host runs microsandbox (msb), which manages lightweight OCI containers
- Each sandbox is a Debian container with Node.js, neovim, and pi pre-installed
- An external llama.cpp server provides the LLM backend for the agent
On a bare host, bootstrap everything in one line:
wget -qO- https://raw.githubusercontent.com/ChumpChief/agent-server-scripts/main/host_scripts/setup_host | bashThis installs curl, git, openssh-server, Node.js (via nvm), microsandbox, and downloads scripts from the repo into ~/bin. After setup, run . ~/.bashrc then sandbox provision.
Run the one-liner from Quick Start, or clone the repo and run:
./host_scripts/setup_hostEither way, this updates system packages, installs curl, git, openssh-server, Node.js (via nvm, latest LTS), and microsandbox globally. Downloads the latest scripts from the repo into ~/bin (added to PATH). Re-run anytime to update.
sandbox provisionRuns an interactive prompt that collects:
- Sandbox name — unique identifier for the container
- AI server — host and port of your llama.cpp server
- GitHub token (optional) — classic PAT with
repoandworkflowscopes
Provisioning installs the following inside the sandbox:
- APT packages (gh, neovim, git, curl, jq, tmux)
- nvm + Node.js (latest LTS)
- pi (global npm install)
pi-llama-cppextension- Git user identity (configurable via env vars)
- llama.cpp server URL in pi settings
- Default working directory set to
~/giton SSH login
sandbox sync-in <name> # host current dir → sandbox ~/sync
sandbox sync-out <name> # sandbox ~/sync → host current dirAfter provisioning, use msb directly for routine operations:
msb ssh my-dev-agent # interactive shell
msb exec my-dev-agent -- nvim
msb stop my-dev-agentKey settings in sandbox are overridable via environment variables:
| Variable | Default | Description |
|---|---|---|
IMAGE |
debian |
Base OCI image |
CPUS |
2 |
CPU count |
MEMORY |
2G |
Memory limit |
OCI_UPPER_SIZE |
8G |
OCI upper filesystem size |
PACKAGES |
gh neovim git curl jq tmux |
APT packages to install |
SHELL |
/bin/bash |
Default shell for interactive sessions |
WORKDIR |
~/git |
Default working directory (SFTP) / SSH login cd target |
GIT_USER_NAME |
ChumpChief-bot |
Git user name |
GIT_USER_EMAIL |
chump.chief.bot@gmail.com |
Git user email |
The provision command also prompts interactively for:
| Prompt | Env override | Description |
|---|---|---|
| Sandbox name | — | Unique container name |
| llama.cpp host | — | Hostname of the llama.cpp server (always prompted) |
| llama.cpp port | — | Port of the llama.cpp server (always prompted) |
| GitHub token | GITHUB_TOKEN |
Classic PAT for repo/workflow access |