← Back to Registry
ComputeSDK
Beta Sandbox Mounting
Run sandboxes using the ComputeSDK compute provider.
Mount the sandbox
Mount a ComputeSDK sandbox into the VM with @rivet-dev/agentos-sandbox.
import { agentOS, setup } from "@rivet-dev/agentos";
import { createSandboxFs, createSandboxBindings } from "@rivet-dev/agentos-sandbox";
import { SandboxAgent } from "sandbox-agent";
import { computesdk } from "sandbox-agent/computesdk";
// Start a ComputeSDK-backed sandbox and mount it into the VM
const sandbox = await SandboxAgent.start({ sandbox: computesdk() });
const vm = agentOS({
mounts: [{ path: "/home/agentos/sandbox", plugin: createSandboxFs({ client: sandbox }) }],
bindings: [createSandboxBindings({ client: sandbox })],
});
export const registry = setup({ use: { vm } });