Root and FUSE (preview)
A preview sandbox template where commands can run as root and FUSE works, for example to mount an S3 bucket. What works, how to keep a mount up across commands, and the limits.
What it is#
On the default template, commands run as an unprivileged user (uid 2000) without sudo, and a root command is refused: sandal exec --root answers 422 capability_unavailable, the CLI exits with code 7, and the message names the missing capability (tenant-root-v1) and the next step.
The preview template, named Preview: root + FUSE, is the same Debian sandbox with two additions:
- Root on request. A command you start as root runs as uid 0 with
HOME=/root. It can install packages withaptand write anywhere, for example/usr/local. Commands you start normally still run as the unprivileged user. - FUSE.
/dev/fuseandfusermount3are available, so FUSE filesystems such asrclone mountwork.
Create a sandbox from it with its template id (we send it to you when we switch the preview on for your project):
sandal create --template <preview-template-id>Run a command as root#
sandal exec --root <sandbox> -- id # uid=0(root)
sandal exec --root <sandbox> -- sh -c 'apt-get update && apt-get install -y rclone'The SDKs take the same option per command: TypeScript sb.exec(cmd, { user: "root" }), Python sb.exec(cmd, user="root"), Go sandal.SandalCommandOptions{User: "root"}. Root commands always go over the API path, not the direct exec path, and --root cannot be combined with --secret or a live terminal (-it).
Mount an S3 bucket#
Start the FUSE daemon detached from the command that mounts it: in its own session (setsid), in the background (--daemon), with its input and output redirected. The mount then stays up after that exec ends, and every later exec sees it, including commands that do not run as root:
# an rclone config for your bucket, copied in as a file (keys never go on a command line)
sandal cp ./rclone.conf <sandbox>:/workspace/rclone.conf
sandal exec --root <sandbox> -- sh -c 'mkdir -p /mnt/bucket && setsid rclone mount --config /workspace/rclone.conf s3:my-bucket /mnt/bucket --allow-other --vfs-cache-mode writes --daemon </dev/null >/tmp/mount.log 2>&1'
sandal exec <sandbox> -- ls /mnt/bucket # a later exec, as the normal userrclone.conf holds a standard rclone S3 remote named s3 (type = s3, your provider, keys and region). --allow-other lets users other than root use the mount.
If the daemon stays attached to the exec instead (started in the foreground, or holding the command's output), that exec never finishes and is ended at its timeout, together with the mount. Plain nohup … & without setsid did not keep a background process alive in our tests.
Limits#
- Where a mount is visible. A detached mount is visible to later execs, terminals and file operations, but not to SSH sessions.
- Mounts do not survive a stop and start, a pause and resume, or a fork: mount again afterwards.
- Fewer hosts. These sandboxes run only on hosts that support the template, so there is less capacity than for the default template, and a create may wait (
waiting_for_capacity). - The first create can take minutes. The first create on a host that has not run the template yet took about 4 minutes in our tests; later creates took about 30 seconds (November 28, 2026). There is no warm pool for it yet.
- Brokered secrets were verified on this template on November 28, 2026; as everywhere, wait for
activebefore the first request to a credential host. - Preview. The template id changes when the template is updated, and the behaviour may change before it is generally available.