agent-sandbox: Manage Isolated Stateful Workloads on Kubernetes

Summary
Agent Sandbox adds Kubernetes APIs and controllers for isolated, stateful workloads with stable identity and persistent storage. Use it to run long-lived AI agent environments, development sessions, or other singleton workloads that need managed lifecycle control.
At a glance
- Language
- Go
- License
- Apache-2.0
- Stars
- 4.1k
- Forks
- 541
- Added to OSRepos
- August 8, 2026
- Last analyzed
- October 3, 2026
Topics
Click on any tag to explore related repositories
Use at your own risk
OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.
Overview
Agent Sandbox is a Kubernetes project for managing isolated, stateful workloads that run as single pods with stable identities. Its Sandbox custom resource and controller address workloads that do not fit neatly into stateless Deployments or the numbered replicas of StatefulSets.
The project orchestrates sandbox workloads rather than providing low-level container isolation itself. It can configure pods to use sandbox runtimes through Kubernetes RuntimeClass, and its optional extensions add reusable templates, claims, and warm pools.
Key Features
- Declarative
Sandboxresources for managing a single workload pod. - Stable hostname and network identity for each sandbox.
- Optional persistent storage that can survive restarts.
- Controller-managed lifecycle, including scheduled deletion, pausing, and resuming.
- Optional
SandboxTemplateresources for reusable configurations. - Optional
SandboxClaimandSandboxWarmPoolresources to allocate pre-warmed sandboxes. - Go and Python SDKs for programmatic access, plus an optional HTTP Sandbox Router.
- Runtime integration through Kubernetes
RuntimeClass, with runtimes such as gVisor or Kata Containers identified in the README.
Use Cases
- AI agent teams can provide isolated environments for running LLM-generated code, especially when workloads need persistent state and stable access.
- Reinforcement-learning and evaluation platform developers can use warm pools to reduce the setup delay when allocating sandboxes in repeated execution loops.
- Development-platform operators can offer persistent, network-accessible environments that behave like individual workspaces.
- Notebook and research-tool operators can manage single-container sessions that need a stable identity across restarts.
- Teams running singleton services, such as build agents or small databases, can use a dedicated workload abstraction instead of combining a size-one StatefulSet with supporting resources.
Project Facts
- Language: Go
- License: Apache-2.0
- Stars: 4.1k
- Forks: 541
- Topics: agent, ai, kubernetes, rl, sandbox
- Archived: false
Getting Started
Install the core controller and extensions on a Kubernetes cluster:
kubectl apply -f https://github.com/kubernetes-sigs/agent-sandbox/releases/latest/download/sandbox-with-extensions.yaml
For version-pinned installs, core-only installation, SDK setup, and usage details, see the repository README and Getting Started guide.
Alternatives
- agent-sandbox: It exposes sandbox lifecycle operations through a REST API and MCP server, while agent-sandbox provides Kubernetes APIs and controllers for stateful workloads.
- OpenSandbox: It offers a shared API for isolated code, command, and browser environments, rather than Kubernetes-native controllers for stable, persistent workloads.
Considerations
- Agent Sandbox is an orchestrator, not a sandbox runtime. Isolation depends on the runtime and pod configuration selected by the operator.
- It requires a Kubernetes cluster where its controller and custom resource definitions can be installed.
- Extensions are optional and add their own custom resources and controllers; install them only if templates, claims, or warm pools are needed.
- Deleting the custom resource definitions cascade-deletes resources of those types, so review existing sandboxes and extension resources before uninstalling.
- The project describes deep hibernation and other advanced sandbox characteristics as goals or areas being explored, so do not assume every desired capability is currently available.
Found this useful?
Share it with someone who would like agent-sandbox.
Comparisons
Source repository
Open the original repository on GitHub.
21 counted GitHub visits
Related repositories
Similar repositories that may be relevant next.

ksail: Create and Operate Kubernetes Clusters
September 27, 2026
KSail is a Go-based toolkit for creating and operating Kubernetes clusters across local, nested, and cloud providers. It brings provisioning, GitOps, secrets, cluster operations, and AI interfaces into one tool, for developers and platform teams who want a unified workflow.

llm-d-router: Route Inference Requests Intelligently
September 25, 2026
llm-d Router directs inference requests using model-serving signals such as KV-cache locality, load, and priority. It is for teams running LLM serving on Kubernetes that need proxy-integrated routing and request flow control.

inference-gateway: Unify LLM Providers Behind One API
September 25, 2026
Inference Gateway proxies requests to cloud and local LLM providers through compatible APIs. It is suited to teams building provider-flexible AI services that need self-hosting, MCP tools, authentication, or observability.

n8n-sandbox-service: Run Commands in Isolated Environments
September 17, 2026
n8n-sandbox-service provides an API for creating isolated, on-demand environments to run commands and manage files. It is intended for teams that need to execute work in containers or Firecracker microVMs and manage those environments centrally.