🎉 Giảm 20% cho đơn hàng đầu tiên!✦🚚 Miễn phí vận chuyển cho đơn trên 500.000₫✦⚡ Flash Sale — Số lượng có hạn!✦🎁 Quà tặng kèm cho đơn từ 1.000.000₫✦🎉 Giảm 20% cho đơn hàng đầu tiên!✦🚚 Miễn phí vận chuyển cho đơn trên 500.000₫✦⚡ Flash Sale — Số lượng có hạn!✦🎁 Quà tặng kèm cho đơn từ 1.000.000₫✦
Substrate: Zero-Trust Sandboxing for Millions of Agents on Kubernetes — Idle Agents Cost Nothing
Quay lại Blog

Substrate: Zero-Trust Sandboxing for Millions of Agents on Kubernetes — Idle Agents Cost Nothing

19 tháng 11, 20268 phút đọcVũ Khôi
English
#English#AI Agent#Hạ tầng & DevOps
Vũ Khôi

Vũ Khôi

Tác giả tại Wotech Electronics Blog

Screenshot of the Agent Substrate GitHub README: zero-trust sandboxing for millions of agents on Kubernetes, 250 agents on 8 worker pods

Substrate: Zero-Trust Sandboxing for Millions of Agents on Kubernetes — Idle Agents Cost Nothing

Creating an agent with VibeCoding is easy, but running an agent for real is hard: agents run untrusted code, a prompt-injected agent leaks keys, an agent waiting for a model still eats RAM, 100 agents mean 100 containers, and server costs multiply by 10. That is the problem Substrate exists to solve — according to a post by the Code Web Không Khó page (18/11/2026): zero-trust sandboxing for millions of agents on Kubernetes, Apache-2.0 license, v1.0.0, 7.5k stars on GitHub per the README screenshot in the post. All figures, features, and views in this article follow the post and have not been independently verified by Wotech.

Quick answer: According to the post, Substrate is a runtime that runs agents in sandboxes, with strengthened security, designed to safely run millions of agents and tools at up to 10 times the density of ordinary containers. Each agent gets separate compute, identity, network, and storage; sensitive keys never sit within reach of untrusted code; it supports multiple sandbox technologies including microVMs and gVisor, with unified sandbox lifecycle management. The core principle: agents spend most of their time waiting for a model, a tool, or a human, so Substrate snapshots idle actors out of memory and restores them when a request arrives — a real demo per the post: about 250 stateful actors multiplexed on only 8 physical pods, resume in under 500ms, over 500 activations per second, 10 times the density of ordinary containers. On zero-trust security, every actor runs in its own gVisor sandbox or Cloud Hypervisor microVM, receives a short-lived SPIFFE X.509 certificate by default, never holds JWTs, certs, API keys, or cloud tokens inside the sandbox, and the network is deny-by-default. Substrate is not an agent SDK — it is a low-opinion runtime that forces no framework, running on standard Kubernetes.

A sandbox in the post means the isolated environment an agent runs inside — in Substrate, a gVisor sandbox or VM-grade microVM separating compute, network, and storage — so untrusted code cannot reach keys, data, or other agents, even when prompt-injected.

What is Substrate?

According to the post, Substrate is a runtime that runs agents in sandboxes, with strengthened security, designed to safely run millions of agents and tools at up to 10 times the density of ordinary containers. Each agent gets separate compute, identity, network, and storage. Sensitive keys never sit within reach of untrusted code. It supports multiple sandbox technologies including microVMs and gVisor, with unified sandbox lifecycle management. The key point the post stresses: Substrate is not an agent SDK — it is a low-opinion runtime that forces no framework on you. Workloads running on it need not be AI agents, but autonomous, untrusted agents that mostly sit waiting are exactly what its isolation and scheduling model targets. It runs on standard Kubernetes — Pods, autoscaling, NetworkPolicy — adding agent-specific scheduling, snapshots, identity, and network orchestration. That lets agent, inference, training, and reinforcement learning workloads share one infrastructure.

The core principle: an idle agent must not cost money

According to the post, Substrate maps many Actors onto fewer Workers: an Actor is a stateful workload such as an agent, a Worker is a pool of ready machines. Because agents spend most of their time waiting for a model, a tool, or a human, Substrate snapshots idle actors out of memory and restores them when a request arrives. A real demo per the post: about 250 stateful actors multiplexed on only 8 physical pods.

Mechanism Content per the post
Actor Teleport Pause and restore an actor onto any free worker in the pool, when needed
Full-State Persistence RAM and filesystem state are captured in a snapshot and restored intact after hibernation, with no lost running session or tool state
Oversubscription 10x–30x Pack many stateful actors onto few warm worker pods, paying for compute only when the agent is really thinking or running a tool

Results per the post: resume in under 500ms, over 500 activations per second, 10 times the density of ordinary containers.

How does zero-trust security work?

According to the post, Substrate treats every actor as untrusted and hostile to one another, so multiple tenants can share a physical node without sharing a security boundary:

Protection layer Content per the post
Always sandboxed, VM-grade boundary Every actor runs in its own gVisor sandbox or Cloud Hypervisor microVM, separating compute, network, and storage. No plain Linux containers.
Cryptographic identity per agent Each running actor receives a short-lived SPIFFE X.509 certificate by default; the egress gateway can issue a per-actor JWT when the egress policy requires it. Both carry the actor identity and namespace.
Zero credentials in the sandbox An actor never holds JWTs, certs, API keys, or cloud tokens. The egress gateway injects credentials into approved outbound requests, outside the sandbox — so a prompt-injected or compromised agent has nothing to steal.
Network deny-by-default An actor starts with its own network stack, no way in except through the ingress router, no lateral access to other actors or the control plane, outbound traffic limited by the egress gateway.
Pluggable policy at the edge The egress gateway is the external policy enforcement point, fully replaceable, so you can attach an authorization engine, DLP, prompt-injection scanning, or cloud IAM without putting policy code inside the untrusted sandbox.

Framework-agnostic, no SDK changes needed

According to the post, because Substrate runs standard OCI images in gVisor sandboxes or microVMs and enforces security outside the workload, it can host agents built on any stack without changing SDKs: Agent Development Kit (keeps session state across calls as actor state), LangChain (a drop-in runtime replacement for LangChain agents and tool calls), Claude Code, Codex, and Antigravity (stateful, high-density code environments that keep system and filesystem state across sessions while isolating untrusted code), MCP (deploy MCP servers in sandboxes as Substrate actors, with their own identity and egress control). The ecosystem per the post: Agent Executor, a distributed agent runtime built on Substrate; kagent, a CNCF Sandbox project, a Kubernetes-native framework for building, deploying, and managing agents, using Substrate to run stateful agent workloads in sandboxes.

Apply now: 5 steps to use Substrate the VibeCoding way

According to the post, VibeCoding used to stop at: create 1 agent, run 1 container, 1 broken agent leaks keys, 1 waiting agent costs money. With Substrate, the correct workflow is:

  1. Package your agent as a standard OCI image, no SDK changes needed.
  2. Declare an ActorTemplate, WorkerPool, and namespace, and let Substrate handle scheduling, snapshots, and networking.
  3. Run the agent in a VM-grade sandbox, keep no credentials inside the sandbox, route all outbound requests through the egress gateway.
  4. When the agent is idle, let it hibernate; when a request arrives, teleport it to a free worker, restoring full RAM and filesystem.
  5. When you need to scale, scale the WorkerPool, not the agent count.

This is VibeCoding at the infrastructure layer, per the post: you focus on what the agent does, while Substrate handles running agents safely, cheaply, and without breaking each other.

Frequently asked questions

1. Is Substrate an SDK for building agents? No. According to the post, Substrate is a low-opinion runtime that forces no framework — it runs agents in sandboxes, while building agents still uses your own stack.

2. Why do idle agents cost money, and how does Substrate fix it? According to the post, agents spend most of their time waiting for a model, a tool, or a human but still hold RAM; Substrate snapshots idle actors out of memory and restores them on request — demo: about 250 actors on only 8 physical pods, resume under 500ms.

3. What happens if an agent gets prompt-injected? According to the post, an actor never holds credentials inside the sandbox — the egress gateway injects credentials into approved requests outside the sandbox — so an injected or compromised agent has nothing to steal.

4. Which stacks does Substrate run with? According to the post: Agent Development Kit, LangChain, Claude Code, Codex, Antigravity, and MCP — standard OCI images, no SDK changes.

5. What projects are built on Substrate? According to the post: Agent Executor — a distributed agent runtime built on Substrate; kagent — a CNCF Sandbox project, a Kubernetes-native framework using Substrate to run stateful agent workloads in sandboxes.

Source: post by the Code Web Không Khó page (18/11/2026), summarizing the Substrate repository (Apache-2.0, v1.0.0, 7.5k stars per the README screenshot in the post). All figures, features, and views in this article follow the post and have not been independently verified by Wotech.