Documentation menu

Guides

Agent Sandbox Checklist: What to Test Before You Buy

An agent sandbox should prove isolation, controlled access, reproducible tools, recovery, concurrency, and useful evidence before you rely on it for long-running jobs.

Published

On this page 4 sections
  1. Test long jobs, parallel runs, and recovery
  2. Make the output useful after the run
  3. FAQ
  4. Sources & References

An agent sandbox is only useful when a second run can start with the same tools. Jetty supports and stores custom runtime configurations for this reason, so users can pin language versions, package manager, browser version, system packages, and environment variables that are part of the job.

Ask for a way to pin or build that environment. Jetty supports this through custom Docker sandboxes, so users can launch a runbook in their own Docker containers. You should be able to answer three questions without opening a support ticket: what was installed, when it changed, and how to recreate it. A provider that installs packages during every run may be convenient for exploration but slow and hard to audit in production.

The test is simple. Start from the declared image, print versions for every tool your agent uses, install one package, restart or resume the run, and repeat the version check. Then run the same task in parallel. The outputs should identify the environment clearly enough that a failed run can be reproduced by another engineer.

Browser support is part of the environment, not a footnote. If your agent uses Chromium, Playwright, downloads, screenshots, or a display server, ask whether those pieces are preinstalled, how they are patched, and whether they work in parallel sessions. Jetty's sandbox documentation is a concrete example of the detail to look for: it describes a VM-based sandbox with configurable CPU and memory, network egress controls, a default python312-uv runtime that includes Python, uv, Node, Chromium, and Playwright, and support for custom Docker images so you can bring your own tooling.

Package support also has a security cost. A broad package catalog makes an agent more capable, but it adds patching and supply chain decisions. Prefer a small, declared base and a controlled install step. Keep a manifest with the run result so a later reviewer can tell whether a changed dependency caused the behavior change.

Test long jobs, parallel runs, and recovery

Long-running agents fail in ordinary ways: a process times out, a browser closes, a network call stalls, a worker disappears, or an agent needs to continue after a human review. Your sandbox choice should make those events visible and recoverable.

Check the full lifecycle:

  1. Create a run and measure time to a usable shell, not just time to an API response.
  2. Start a process that writes progress markers while it works.
  3. Pause, resume, stop, or reconnect according to the provider's model.
  4. Confirm which files, processes, sockets, and environment variables survive.
  5. Force a failure and inspect the exit reason, logs, and retained outputs.

E2B's docs say a sandbox can pause when its timeout expires and preserve its state for resume. Modal's sandbox lifecycle docs document a default maximum lifetime of 5 minutes and a configurable maximum of 24 hours, checked November 4, 2026. When evaluating either provider, confirm the current runtime limits against your job's actual duration requirements before treating any capability as a pass.

Parallelism needs a separate acceptance task. Launch several identical jobs and several jobs with different images or secrets. Measure queue time, startup time, completion time, throttling, and whether one job's CPU or memory pressure changes another's result. Ask whether concurrency is limited per account, project, image, region, or plan. A fast single sandbox can still be the wrong tool for an evaluation suite that launches many runs at once.

Recovery is not the same as retry. A retry may start from an empty filesystem and lose the context that mattered. Look for checkpoints, snapshots, durable volumes, resumable sessions, or a clear rule that the job must restart from scratch. Daytona is worth including in this comparison because its sandbox product page gives you another concrete provider to ask about workspace persistence, isolation, and parallel capacity. Do not mark any of those capabilities as passing until the current documentation or a trial proves them.

Make the output useful after the run

The sandbox should leave evidence, not just an exit code. Retain the input, environment description, commands or tool calls, stdout and stderr, screenshots when a browser was used, changed files, exit status, timestamps, and the exact reason a run stopped. Decide which of those may contain personal data or secrets before you store them.

Use a fixed acceptance task that represents real work. For example, ask an agent to inspect a small repository, use a browser to read one page, write a structured result, run a test, and save a manifest. The task should check isolation, network policy, package availability, browser behavior, a long-running process, a deliberate failure, and the final artifact. Run it on every candidate and keep the result beside the configuration that produced it.

Tracing helps when the task fails inside a successful process. Treat tracing as complementary to sandbox evidence. A trace tells you about agent decisions, while the sandbox record tells you what the machine allowed and what it retained.

Jetty's run documentation is a useful model for this evidence layer: it describes replayable runs with inputs, outputs, files, logs, telemetry, and labels. Its evaluation documentation also separates code checks from checklist and judge results. That distinction matters. A judge can say an answer is weak, but a code check can prove that the output file exists and that a result parses.

A practical pass or fail table

CriterionWhy it mattersHow to test itPass mark
IsolationUntrusted code must not cross run boundariesRun a marker and inspect it from a separate runThe second run cannot read the marker
Network and secretsAgents need useful access without silent data lossExercise allowed and denied destinations, then inspect logs and artifactsPolicy is explicit and secrets stay out of evidence
Reproducible environmentFailures are hard to fix when tools driftPrint versions, install a package, resume, and rerunA versioned manifest identifies the environment
Lifecycle and recoveryLong jobs need more than a create endpointInterrupt a job, reconnect, and inspect retained stateThe provider documents what survives and why
Parallel capacityEvaluation suites create burstsLaunch identical and mixed jobs togetherQueueing, limits, and isolation are observable
Browser and toolsAgents often act through browsers and CLIsRun the real browser flow and save its evidenceRequired tools work in the declared runtime
EvidenceAn exit code cannot explain an agent failureInspect traces, logs, files, and checksAnother engineer can replay or diagnose the run

How Jetty scores on this checklist

Jetty's public docs support a strong pass on runbooks, declared runtimes, retained outputs, and evaluation evidence. The runbook documentation describes a job specification with setup, steps, checks, and declared output files. The runtime page documents a VM sandbox, network egress, browser tooling, custom images, and selectable agent runtimes.

Secrets deserve their own test. Jetty injects a short-lived credential only into the process that needs it, keeps it out of logs and saved artifacts, and makes the access path visible after the run. For regional placement, recovery requirements, or any other specific compliance needs, contact us so we can discuss your workload directly.

FAQ

What is an agent sandbox?

An agent sandbox is an isolated runtime where an AI agent can execute commands, inspect files, use tools, and produce outputs under defined permissions. You should evaluate it as both an execution environment and an evidence system, because safe execution without useful logs is difficult to debug.

Is a container enough for an AI agent sandbox?

A container may be enough for a trusted internal task, but you need to verify the isolation boundary for untrusted generated code. Ask whether the platform uses containers, VMs, microVMs, or another design, then test filesystem, process, network, and secret separation between two runs.

How do I test sandbox security for agents?

Use a harmless acceptance task that checks the exact network destinations, tries to read a marker from another run, prints a controlled environment view, and writes a known artifact. Review the policy, logs, and artifacts together. Do not treat a marketing label or a green process exit as a security test.

What should an agent sandbox retain after a run?

Retain the inputs, runtime and package manifest, logs, tool or command trace, exit reason, changed files, and final outputs. If a browser matters, retain the relevant screenshot or page evidence. Redact credentials and decide how long personal or customer data may remain before enabling retention.

How do long-running agent jobs recover?

Recovery depends on the provider's lifecycle model. Test an interruption and then check whether the process, filesystem, network connections, browser state, and outputs survive. If the provider only supports a fresh retry, make the job checkpoint its own progress and make that limitation part of your design.

Should I compare sandboxes by startup speed alone?

No. Startup time matters, but a production agent also needs predictable concurrency, package and browser support, network controls, secret handling, lifecycle recovery, and retained evidence. Measure startup and completion time inside the same acceptance task so speed does not hide a missing capability.

Sources & References

  • Jetty Sandboxes: sandbox, browser, package, and agent runtime details.
  • E2B sandbox lifecycle: VM isolation, pause and resume, and timeouts.
  • Modal Sandboxes: runtimes, lifecycle, readiness, and environment controls.
  • Jetty runbooks: declared work, checks, and output files.

All guides