Security › Job sandboxes

Job sandboxes

For IT leads and admins3 min read

Every job runs in its own locked-down container, its sandbox. It sees its own work folder and nothing else on your server, and it is removed when the job ends.

On this page
  1. The short version
  2. Why jobs run in a sandbox
  3. What a sandbox can and can't do
  4. Each job works on its own copy
  5. Internet access
  6. Check it on your server

The short version

  • One sandbox per job. Each job on the board gets a fresh container that sees only its own work folder.
  • Locked down. It runs as an ordinary user, with extra system permissions removed, a read-only system disk, and no Docker socket or database.
  • Fails closed. If the sandbox can't start, the job fails. It never falls back to running unsandboxed.
  • Not a network jail. Sandboxes can reach the internet. They isolate files and processes, not the network.

Why jobs run in a sandbox

The coding tool a bot uses inside a job doesn't ask for approval at each step. It reads, writes and runs commands on its own, which is what makes it useful. The box around it is what stops it doing damage. A rule the job is told to follow can be ignored; a folder that isn't in its container can't be touched.

The app controls Docker to start and stop these sandboxes. That is why only people you would trust with the server should be admins. See Who you trust.

What a sandbox can and can't do

With SESSION_ISOLATION="docker", the installer default, every job on the board runs in its own container named ok-jail-<card id>.

The sandboxIn practice
Mounts only the job's own work folder and its own home folderNothing else from your server is there: not other jobs' folders, not the live copy of your code, not the server's secrets folder.
Runs as an ordinary user, never rootIt can't change the system inside the container.
Drops every extra Linux capability and sets no-new-privilegesIt can't gain more power while it runs.
Has a read-only system disk, with a small scratch area in /tmpIt can write only to its work folder, its home folder and /tmp.
Has no Docker socket and no databaseIt can't start containers or read the app's data directly. It reaches the app only through the app's API.
Never runs privileged or on the host's networkIt stays inside its own container.
Is removed when the job endsNothing is left running. A container that is still there belongs to a job that is still working.

The job gets only the secrets it is allowed, as environment variables inside its sandbox. Server-only credentials and the encryption key are never there. See How a job is given a secret.

Each job works on its own copy

A card linked to a code repository works on its own copy of that repository, on its own branch, in a folder named after the card. It never edits the live checkout, so two jobs can't overwrite each other's changes. The finished work comes back as a branch or a pull request.

A card with no repository works in its bot's working folder, or in a scratch folder of its own. Files the card had attached are copied in so the job can read them.

Internet access

Sandboxes can reach the internet. A job needs that to talk to your model provider, call the APIs you allowed, and install tools. On a standard install, sandboxes also share a private network with the app so jobs can report progress.

This is file and process isolation, not a network jail. A job could send what it can read to an outside address. Keep what a job can read small: give bots only the knowledge-base folders and secrets they need.

Check it on your server

To see which jobs are running right now:

sudo docker ps | grep ok-jail

To see what one sandbox has mounted (use the card's id):

sudo docker inspect -f '{{range .Mounts}}{{.Destination}} {{end}}' ok-jail-<card id>

It should list the work folder (/workspace) and the home folder, plus a model sign-in folder for Codex or Grok jobs. The installer's verify.sh runs a test card and checks the same thing.

The exact settings are in session-jail.ts. How a job is put together and run, step by step: How a job runs.

Last checked against Operation Kit main (f504a64), 11 Nov 2026Suggest an edit