- Outside the sandbox — use the Mesa SDK (TypeScript or Python) to create repos, manage API keys, and orchestrate your workflow.
- Inside the sandbox — install the
mesaCLI, configure it with your API key, and runmesa mount --daemonizeto mount your repos as local directories. - Run your agent —
cdinto the mount path and launch your agent (e.g. Claude Code, Codex, or a custom agent). Any file edits are automatically persisted back to Mesa.
Alpine-based setup (default image)
Blaxel’s default image is Alpine-based. The Mesa CLI is distributed as a.deb package, so on Alpine you need to extract it manually using dpkg-deb:
Debian-based setup (custom template)
For a cleaner setup, you can build a custom Debian-based Blaxel template that uses the standard Mesa install script. Create a Dockerfile:bl deploy, then reference your template when creating sandboxes:
Mount Mesa
Once the CLI is installed (via either method), configure and mount:Tips
- Use scoped, short-lived API keys. Create a dedicated API key for each sandbox session with only the scopes it needs. See Auth and Permissions for details.
- Enable prefetching. Mesa prefetches repository data in the background to reduce latency. This is especially useful in sandboxes where startup time matters. Prefetching is enabled by default, but you can further tune it to your needs in your
config.toml. - Use
--daemonize. Always runmesa mount --daemonizein sandbox environments so Mesa runs as a background process and doesn’t block your agent’s terminal. - Prefer the Debian-based template for production use — it avoids the Alpine workarounds and uses the standard install path.

