From 2ee33441065101d28afbb693fe80f97e89a45255 Mon Sep 17 00:00:00 2001 From: pimlock Date: Sat, 14 Mar 2026 00:20:55 +0000 Subject: [PATCH] =?UTF-8?q?Deploy=20preview=20for=20PR=20291=20?= =?UTF-8?q?=F0=9F=9B=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pr-preview/pr-291/about/architecture.json | 2 +- pr-preview/pr-291/about/overview.json | 2 +- pr-preview/pr-291/about/release-notes.json | 2 +- pr-preview/pr-291/get-started/quickstart.json | 2 +- pr-preview/pr-291/inference/configure.json | 2 +- pr-preview/pr-291/inference/index.json | 2 +- pr-preview/pr-291/reference/default-policy.json | 2 +- pr-preview/pr-291/reference/policy-schema.json | 2 +- pr-preview/pr-291/reference/support-matrix.json | 2 +- pr-preview/pr-291/resources/eula.json | 2 +- pr-preview/pr-291/sandboxes/community-sandboxes.json | 2 +- pr-preview/pr-291/sandboxes/create-and-manage.json | 2 +- pr-preview/pr-291/sandboxes/index.json | 2 +- pr-preview/pr-291/sandboxes/policies.json | 2 +- pr-preview/pr-291/sandboxes/providers.json | 2 +- pr-preview/pr-291/tutorials/github-sandbox.json | 2 +- 16 files changed, 16 insertions(+), 16 deletions(-) diff --git a/pr-preview/pr-291/about/architecture.json b/pr-preview/pr-291/about/architecture.json index e2b7b472f..54cf96188 100644 --- a/pr-preview/pr-291/about/architecture.json +++ b/pr-preview/pr-291/about/architecture.json @@ -1 +1 @@ -{"id":"about/architecture","title":"How OpenShell Works","url":"about/architecture.html","last_modified":"2026-03-14T00:12:41.691001+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"OpenShell architecture overview covering the gateway, sandbox, policy engine, and privacy router.","tags":["AI Agents","Sandboxing","Security","Architecture"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"How OpenShell Works OpenShell runs as a K3s Kubernetes cluster inside a Docker container. Each sandbox is an isolated Kubernetes pod managed through the gateway. Four components work together to keep agents secure. Components The following table describes each component and its role in the system: Component Role Gateway Control-plane API that coordinates sandbox lifecycle and state, acts as the auth boundary, and brokers requests across the platform. Sandbox Isolated runtime that includes container supervision and policy-enforced egress routing. Policy Engine Policy definition and enforcement layer for filesystem, network, and process constraints. Defense in depth enforces policies from the application layer down to infrastructure and kernel layers. Privacy Router Privacy-aware LLM routing layer that keeps sensitive context on sandbox compute and routes based on cost and privacy policy. How a Request Flows Every outbound connection from agent code passes through the same decision path: The agent process opens an outbound connection (API call, package install, git clone, and so on). The proxy inside the sandbox intercepts the connection and identifies which binary opened it. The proxy queries the policy engine with the destination, port, and calling binary. The policy engine returns one of three decisions: Allow — the destination and binary match a policy block. Traffic flows directly to the external service. Route for inference — no policy block matched, but inference routing is configured. The privacy router intercepts the request, strips the original credentials, injects the configured backend credentials, and forwards to the managed model endpoint. Deny — no match and no inference route. The connection is blocked and logged. For REST endpoints with TLS termination enabled, the proxy also decrypts TLS and checks each HTTP request against per-method, per-path rules before allowing it through. Deployment Modes OpenShell can run locally or on a remote host. The architecture is identical in both cases — only the Docker container location changes. Local : the k3s cluster runs inside Docker on your workstation. The CLI provisions it automatically on first use. Remote : the cluster runs on a remote host. Deploy with openshell gateway start --remote user@host . For example, connect to your DGX Spark. $ openshell gateway start --remote @.local\nopenshell status\nNext Steps Continue with one of the following: To create your first sandbox, refer to the Quickstart . To learn how OpenShell enforces isolation across all protection layers, refer to Sandboxes","format":"text","summary":"OpenShell runs as a K3s Kubernetes cluster inside a Docker container. Each sandbox is an isolated Kubernetes pod managed through the gateway. Four components work together to keep agents secure.","headings":[{"text":"How OpenShell Works","level":1},{"text":"Components","level":2},{"text":"How a Request Flows","level":2},{"text":"Deployment Modes","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file +{"id":"about/architecture","title":"How OpenShell Works","url":"about/architecture.html","last_modified":"2026-03-14T00:20:51.606263+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"OpenShell architecture overview covering the gateway, sandbox, policy engine, and privacy router.","tags":["AI Agents","Sandboxing","Security","Architecture"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"How OpenShell Works OpenShell runs as a K3s Kubernetes cluster inside a Docker container. Each sandbox is an isolated Kubernetes pod managed through the gateway. Four components work together to keep agents secure. Components The following table describes each component and its role in the system: Component Role Gateway Control-plane API that coordinates sandbox lifecycle and state, acts as the auth boundary, and brokers requests across the platform. Sandbox Isolated runtime that includes container supervision and policy-enforced egress routing. Policy Engine Policy definition and enforcement layer for filesystem, network, and process constraints. Defense in depth enforces policies from the application layer down to infrastructure and kernel layers. Privacy Router Privacy-aware LLM routing layer that keeps sensitive context on sandbox compute and routes based on cost and privacy policy. How a Request Flows Every outbound connection from agent code passes through the same decision path: The agent process opens an outbound connection (API call, package install, git clone, and so on). The proxy inside the sandbox intercepts the connection and identifies which binary opened it. The proxy queries the policy engine with the destination, port, and calling binary. The policy engine returns one of three decisions: Allow — the destination and binary match a policy block. Traffic flows directly to the external service. Route for inference — no policy block matched, but inference routing is configured. The privacy router intercepts the request, strips the original credentials, injects the configured backend credentials, and forwards to the managed model endpoint. Deny — no match and no inference route. The connection is blocked and logged. For REST endpoints with TLS termination enabled, the proxy also decrypts TLS and checks each HTTP request against per-method, per-path rules before allowing it through. Deployment Modes OpenShell can run locally or on a remote host. The architecture is identical in both cases — only the Docker container location changes. Local : the k3s cluster runs inside Docker on your workstation. The CLI provisions it automatically on first use. Remote : the cluster runs on a remote host. Deploy with openshell gateway start --remote user@host . For example, connect to your DGX Spark. $ openshell gateway start --remote @.local\nopenshell status\nNext Steps Continue with one of the following: To create your first sandbox, refer to the Quickstart . To learn how OpenShell enforces isolation across all protection layers, refer to Sandboxes","format":"text","summary":"OpenShell runs as a K3s Kubernetes cluster inside a Docker container. Each sandbox is an isolated Kubernetes pod managed through the gateway. Four components work together to keep agents secure.","headings":[{"text":"How OpenShell Works","level":1},{"text":"Components","level":2},{"text":"How a Request Flows","level":2},{"text":"Deployment Modes","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/about/overview.json b/pr-preview/pr-291/about/overview.json index 524a0ca76..455c187ac 100644 --- a/pr-preview/pr-291/about/overview.json +++ b/pr-preview/pr-291/about/overview.json @@ -1 +1 @@ -{"id":"about/overview","title":"Overview of NVIDIA OpenShell","url":"about/overview.html","last_modified":"2026-03-14T00:12:41.696175+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"OpenShell is the safe, private runtime for autonomous AI agents. Run agents in sandboxed environments that protect your data, credentials, and infrastructure.","tags":["AI Agents","Sandboxing","Security","Privacy","Inference Routing"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Overview of NVIDIA OpenShell NVIDIA OpenShell is an open-source runtime for executing autonomous AI agents in sandboxed environments with kernel-level isolation. It combines sandbox runtime controls and a declarative YAML policy so teams can run agents without giving them unrestricted access to local files, credentials, and external networks. Why OpenShell Exists AI agents are most useful when they can read files, install packages, call APIs, and use credentials. That same access can create material risk. OpenShell is designed for this tradeoff: preserve agent capability while enforcing explicit controls over what the agent can access. Common Risks and Controls The table below summarizes common failure modes and how OpenShell mitigates them. Threat Without controls With OpenShell Data exfiltration Agent uploads source code or internal files to unauthorized endpoints. Network policies allow only approved destinations; other outbound traffic is denied. Credential theft Agent reads local secrets such as SSH keys or cloud credentials. Filesystem restrictions (Landlock) confine access to declared paths only. Unauthorized API usage Agent sends prompts or data to unapproved model providers. Privacy routing and network policies control where inference traffic can go. Privilege escalation Agent attempts sudo , setuid paths, or dangerous syscall behavior. Unprivileged process identity and seccomp restrictions block escalation paths. Protection Layers at a Glance OpenShell applies defense in depth across the following policy domains. Layer What it protects When it applies Filesystem Prevents reads/writes outside allowed paths. Locked at sandbox creation. Network Blocks unauthorized outbound connections. Hot-reloadable at runtime. Process Blocks privilege escalation and dangerous syscalls. Locked at sandbox creation. Inference Reroutes model API calls to controlled backends. Hot-reloadable at runtime. For details, refer to Built-in Default Policy and Customize Sandbox Policies . Common Use Cases OpenShell supports a range of agent deployment patterns. Use Case Description Secure coding agents Run Claude Code, OpenCode, or OpenClaw with constrained file and network access. Private enterprise development Route inference to self-hosted or private backends while keeping sensitive context under your control. Compliance and audit Treat policy YAML as version-controlled security controls that can be reviewed and audited. Reusable environments Use community sandbox images or bring your own containerized runtime. Next Steps Explore these topics to go deeper: To understand the components that make up the OpenShell runtime, refer to the Architecture Overview . To install the CLI and create your first sandbox, refer to the Quickstart . To learn how OpenShell enforces isolation across all protection layers, refer to Sandboxes","format":"text","summary":"NVIDIA OpenShell is an open-source runtime for executing autonomous AI agents in sandboxed environments with kernel-level isolation. It combines sandbox runtime controls and a declarative YAML policy so teams can run agents without giving them unrestricted access to local files, credentials, and ...","headings":[{"text":"Overview of NVIDIA OpenShell","level":1},{"text":"Why OpenShell Exists","level":2},{"text":"Common Risks and Controls","level":2},{"text":"Protection Layers at a Glance","level":2},{"text":"Common Use Cases","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file +{"id":"about/overview","title":"Overview of NVIDIA OpenShell","url":"about/overview.html","last_modified":"2026-03-14T00:20:51.611939+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"OpenShell is the safe, private runtime for autonomous AI agents. Run agents in sandboxed environments that protect your data, credentials, and infrastructure.","tags":["AI Agents","Sandboxing","Security","Privacy","Inference Routing"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Overview of NVIDIA OpenShell NVIDIA OpenShell is an open-source runtime for executing autonomous AI agents in sandboxed environments with kernel-level isolation. It combines sandbox runtime controls and a declarative YAML policy so teams can run agents without giving them unrestricted access to local files, credentials, and external networks. Why OpenShell Exists AI agents are most useful when they can read files, install packages, call APIs, and use credentials. That same access can create material risk. OpenShell is designed for this tradeoff: preserve agent capability while enforcing explicit controls over what the agent can access. Common Risks and Controls The table below summarizes common failure modes and how OpenShell mitigates them. Threat Without controls With OpenShell Data exfiltration Agent uploads source code or internal files to unauthorized endpoints. Network policies allow only approved destinations; other outbound traffic is denied. Credential theft Agent reads local secrets such as SSH keys or cloud credentials. Filesystem restrictions (Landlock) confine access to declared paths only. Unauthorized API usage Agent sends prompts or data to unapproved model providers. Privacy routing and network policies control where inference traffic can go. Privilege escalation Agent attempts sudo , setuid paths, or dangerous syscall behavior. Unprivileged process identity and seccomp restrictions block escalation paths. Protection Layers at a Glance OpenShell applies defense in depth across the following policy domains. Layer What it protects When it applies Filesystem Prevents reads/writes outside allowed paths. Locked at sandbox creation. Network Blocks unauthorized outbound connections. Hot-reloadable at runtime. Process Blocks privilege escalation and dangerous syscalls. Locked at sandbox creation. Inference Reroutes model API calls to controlled backends. Hot-reloadable at runtime. For details, refer to Built-in Default Policy and Customize Sandbox Policies . Common Use Cases OpenShell supports a range of agent deployment patterns. Use Case Description Secure coding agents Run Claude Code, OpenCode, or OpenClaw with constrained file and network access. Private enterprise development Route inference to self-hosted or private backends while keeping sensitive context under your control. Compliance and audit Treat policy YAML as version-controlled security controls that can be reviewed and audited. Reusable environments Use community sandbox images or bring your own containerized runtime. Next Steps Explore these topics to go deeper: To understand the components that make up the OpenShell runtime, refer to the Architecture Overview . To install the CLI and create your first sandbox, refer to the Quickstart . To learn how OpenShell enforces isolation across all protection layers, refer to Sandboxes","format":"text","summary":"NVIDIA OpenShell is an open-source runtime for executing autonomous AI agents in sandboxed environments with kernel-level isolation. It combines sandbox runtime controls and a declarative YAML policy so teams can run agents without giving them unrestricted access to local files, credentials, and ...","headings":[{"text":"Overview of NVIDIA OpenShell","level":1},{"text":"Why OpenShell Exists","level":2},{"text":"Common Risks and Controls","level":2},{"text":"Protection Layers at a Glance","level":2},{"text":"Common Use Cases","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/about/release-notes.json b/pr-preview/pr-291/about/release-notes.json index 2d15de34a..6e5ba31b3 100644 --- a/pr-preview/pr-291/about/release-notes.json +++ b/pr-preview/pr-291/about/release-notes.json @@ -1 +1 @@ -{"id":"about/release-notes","title":"NVIDIA OpenShell Release Notes","url":"about/release-notes.html","last_modified":"2026-03-14T00:12:41.701612+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Track the latest changes and improvements to NVIDIA OpenShell.","tags":["Release Notes","Changelog","AI Agents"],"topics":["Generative AI","Cybersecurity"],"content_type":"reference","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"NVIDIA OpenShell Release Notes Track the latest changes and improvements to NVIDIA OpenShell\nThis page covers the highlights of the release\nFor more details, refer to the OpenShell GitHub Releases . 0.1.0 This is the first release of NVIDIA OpenShell. It introduces sandboxed AI agent execution with kernel-level isolation, policy enforcement, and credential management. Highlights Introduces sandboxed AI agent execution with kernel-level isolation, policy enforcement, and credential management. Introduces the openshell CLI for creating, managing, and customizing sandboxes. Introduces the openshell-gateway service for managing the gateway and sandboxes. Introduces the openshell-sandbox service for running the sandboxed agent","format":"text","summary":"Track the latest changes and improvements to NVIDIA OpenShell. This page covers the highlights of the release. For more details, refer to the OpenShell GitHub Releases.","headings":[{"text":"NVIDIA OpenShell Release Notes","level":1},{"text":"0.1.0","level":2},{"text":"Highlights","level":3}]} \ No newline at end of file +{"id":"about/release-notes","title":"NVIDIA OpenShell Release Notes","url":"about/release-notes.html","last_modified":"2026-03-14T00:20:51.617016+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Track the latest changes and improvements to NVIDIA OpenShell.","tags":["Release Notes","Changelog","AI Agents"],"topics":["Generative AI","Cybersecurity"],"content_type":"reference","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"NVIDIA OpenShell Release Notes Track the latest changes and improvements to NVIDIA OpenShell\nThis page covers the highlights of the release\nFor more details, refer to the OpenShell GitHub Releases . 0.1.0 This is the first release of NVIDIA OpenShell. It introduces sandboxed AI agent execution with kernel-level isolation, policy enforcement, and credential management. Highlights Introduces sandboxed AI agent execution with kernel-level isolation, policy enforcement, and credential management. Introduces the openshell CLI for creating, managing, and customizing sandboxes. Introduces the openshell-gateway service for managing the gateway and sandboxes. Introduces the openshell-sandbox service for running the sandboxed agent","format":"text","summary":"Track the latest changes and improvements to NVIDIA OpenShell. This page covers the highlights of the release. For more details, refer to the OpenShell GitHub Releases.","headings":[{"text":"NVIDIA OpenShell Release Notes","level":1},{"text":"0.1.0","level":2},{"text":"Highlights","level":3}]} \ No newline at end of file diff --git a/pr-preview/pr-291/get-started/quickstart.json b/pr-preview/pr-291/get-started/quickstart.json index 356855eaf..1ff842635 100644 --- a/pr-preview/pr-291/get-started/quickstart.json +++ b/pr-preview/pr-291/get-started/quickstart.json @@ -1 +1 @@ -{"id":"get-started/quickstart","title":"Quickstart","url":"get-started/quickstart.html","last_modified":"2026-03-14T00:12:41.708132+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Install the OpenShell CLI and create your first sandboxed AI agent in two commands.","tags":["AI Agents","Sandboxing","Installation","Quickstart"],"topics":["Generative AI","Cybersecurity"],"content_type":"get_started","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Quickstart This page gets you from zero to a running, policy-enforced sandbox in two commands. Prerequisites Before you begin, make sure you have: Python 3.12 or later uv installed Docker Desktop running on your machine Install the OpenShell CLI Install the openshell package into a virtual environment. Activate your virtual environment: uv venv && source .venv/bin/activate\nInstall the CLI: uv pip install openshell\nConnect to a Remote Gateway (Optional) If you’re running locally, skip this step. The OpenShell CLI creates a gateway automatically when you create your first sandbox. Brev Deploy an OpenShell gateway on Brev by hitting Deploy on the OpenShell Launchable . After the instance is running, find the gateway URL in the Brev console under Using Secure Links . Copy the shareable URL for port 8080 — this is the gateway endpoint. $ openshell gateway add https://.brevlab.com\nopenshell status\nDGX Spark Set up your Spark with NVIDIA Sync first, or make sure SSH access is configured (such as SSH keys added to the host). Deploy to a DGX Spark machine over SSH: $ openshell gateway start --remote @.local\nopenshell status\nAfter openshell status shows the gateway as healthy, all subsequent commands route through the SSH tunnel. Create Your First OpenShell Sandbox Choose the tab that matches your agent: Claude Code Run the following command to create a sandbox with Claude Code: $ openshell sandbox create -- claude\nThe CLI prompts you to create a provider from local credentials — type yes to continue. If ANTHROPIC_API_KEY is set in your environment, it is picked up automatically. If not, you can configure it from inside the sandbox after it launches. OpenCode Run the following command to create a sandbox with OpenCode: $ openshell sandbox create -- opencode\nThe CLI prompts you to create a provider from local credentials. Type yes to continue. If OPENAI_API_KEY or OPENROUTER_API_KEY is set in your environment, it is picked up automatically. If not, you can configure it from inside the sandbox after it launches. Codex Run the following command to create a sandbox with Codex: $ openshell sandbox create -- codex\nThe CLI prompts you to create a provider from local credentials. Type yes to continue. If OPENAI_API_KEY is set in your environment, it is picked up automatically. If not, you can configure it from inside the sandbox after it launches. OpenClaw Run the following command to create a sandbox with OpenClaw: $ openshell sandbox create --from openclaw\nThe --from flag pulls a pre-built sandbox definition from the OpenShell Community catalog. Each definition bundles a container image, a tailored policy, and optional skills into a single package. Community Sandbox You can use the --from flag to pull other OpenShell sandbox images from the NVIDIA Container Registry . For example, to pull the base image, run the following command: $ openshell sandbox create --from base","format":"text","summary":"This page gets you from zero to a running, policy-enforced sandbox in two commands.","headings":[{"text":"Quickstart","level":1},{"text":"Prerequisites","level":2},{"text":"Install the OpenShell CLI","level":2},{"text":"Connect to a Remote Gateway (Optional)","level":2},{"text":"Create Your First OpenShell Sandbox","level":2}]} \ No newline at end of file +{"id":"get-started/quickstart","title":"Quickstart","url":"get-started/quickstart.html","last_modified":"2026-03-14T00:20:51.623500+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Install the OpenShell CLI and create your first sandboxed AI agent in two commands.","tags":["AI Agents","Sandboxing","Installation","Quickstart"],"topics":["Generative AI","Cybersecurity"],"content_type":"get_started","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Quickstart This page gets you from zero to a running, policy-enforced sandbox in two commands. Prerequisites Before you begin, make sure you have: Python 3.12 or later uv installed Docker Desktop running on your machine Install the OpenShell CLI Install the openshell package into a virtual environment. Activate your virtual environment: uv venv && source .venv/bin/activate\nInstall the CLI: uv pip install openshell\nConnect to a Remote Gateway (Optional) If you’re running locally, skip this step. The OpenShell CLI creates a gateway automatically when you create your first sandbox. Brev Deploy an OpenShell gateway on Brev by hitting Deploy on the OpenShell Launchable . After the instance is running, find the gateway URL in the Brev console under Using Secure Links . Copy the shareable URL for port 8080 — this is the gateway endpoint. $ openshell gateway add https://.brevlab.com\nopenshell status\nDGX Spark Set up your Spark with NVIDIA Sync first, or make sure SSH access is configured (such as SSH keys added to the host). Deploy to a DGX Spark machine over SSH: $ openshell gateway start --remote @.local\nopenshell status\nAfter openshell status shows the gateway as healthy, all subsequent commands route through the SSH tunnel. Create Your First OpenShell Sandbox Choose the tab that matches your agent: Claude Code Run the following command to create a sandbox with Claude Code: $ openshell sandbox create -- claude\nThe CLI prompts you to create a provider from local credentials — type yes to continue. If ANTHROPIC_API_KEY is set in your environment, it is picked up automatically. If not, you can configure it from inside the sandbox after it launches. OpenCode Run the following command to create a sandbox with OpenCode: $ openshell sandbox create -- opencode\nThe CLI prompts you to create a provider from local credentials. Type yes to continue. If OPENAI_API_KEY or OPENROUTER_API_KEY is set in your environment, it is picked up automatically. If not, you can configure it from inside the sandbox after it launches. Codex Run the following command to create a sandbox with Codex: $ openshell sandbox create -- codex\nThe CLI prompts you to create a provider from local credentials. Type yes to continue. If OPENAI_API_KEY is set in your environment, it is picked up automatically. If not, you can configure it from inside the sandbox after it launches. OpenClaw Run the following command to create a sandbox with OpenClaw: $ openshell sandbox create --from openclaw\nThe --from flag pulls a pre-built sandbox definition from the OpenShell Community catalog. Each definition bundles a container image, a tailored policy, and optional skills into a single package. Community Sandbox You can use the --from flag to pull other OpenShell sandbox images from the NVIDIA Container Registry . For example, to pull the base image, run the following command: $ openshell sandbox create --from base","format":"text","summary":"This page gets you from zero to a running, policy-enforced sandbox in two commands.","headings":[{"text":"Quickstart","level":1},{"text":"Prerequisites","level":2},{"text":"Install the OpenShell CLI","level":2},{"text":"Connect to a Remote Gateway (Optional)","level":2},{"text":"Create Your First OpenShell Sandbox","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/inference/configure.json b/pr-preview/pr-291/inference/configure.json index c3d711681..dfaf7582d 100644 --- a/pr-preview/pr-291/inference/configure.json +++ b/pr-preview/pr-291/inference/configure.json @@ -1 +1 @@ -{"id":"inference/configure","title":"Configure Inference Routing","url":"inference/configure.html","last_modified":"2026-03-14T00:12:41.715434+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Set up the managed local inference endpoint with provider credentials and model configuration.","tags":["Inference Routing","Configuration","Privacy","LLM","Provider"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Configure Inference Routing This page covers the managed local inference endpoint ( https://inference.local ). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details. The configuration consists of two values: Value Description Provider record The credential backend OpenShell uses to authenticate with the upstream model host. Model ID The model to use for generation requests. Step 1: Create a Provider Create a provider that holds the backend credentials you want OpenShell to use. NVIDIA API Catalog $ openshell provider create --name nvidia-prod --type nvidia --from-existing\nThis reads NVIDIA_API_KEY from your environment. Local / self-hosted endpoint $ openshell provider create\nname my-local-model\ntype openai\ncredential OPENAI_API_KEY=empty-if-not-required\nconfig OPENAI_BASE_URL=http://192.168.10.15/v1\nUse --config OPENAI_BASE_URL to point to any OpenAI-compatible server running on your network. Set OPENAI_API_KEY to a dummy value if the server does not require authentication. Anthropic $ openshell provider create --name anthropic-prod --type anthropic --from-existing\nThis reads ANTHROPIC_API_KEY from your environment. Step 2: Set Inference Routing Point inference.local at that provider and choose the model to use: $ openshell inference set\nprovider nvidia-prod\nmodel nvidia/nemotron-3-nano-30b-a3b\nStep 3: Verify the Active Config Confirm that the provider and model are set correctly: $ openshell inference get\nGateway inference\nProvider: nvidia-prod\nModel: nvidia/nemotron-3-nano-30b-a3b\nVersion: 1\nStep 4: Update Part of the Config Use update when you want to change only one field: $ openshell inference update --model nvidia/nemotron-3-nano-30b-a3b\nOr switch providers without repeating the current model: $ openshell inference update --provider openai-prod\nUse It from a Sandbox After inference is configured, code inside any sandbox can call https://inference.local directly: from openai import OpenAI\nclient = OpenAI(base_url=\"https://inference.local/v1\", api_key=\"dummy\nresponse = client.chat.completions.create\nmodel=\"anything\nmessages=[{\"role\": \"user\", \"content\": \"Hello\nThe client-supplied model is ignored for generation requests. OpenShell rewrites it to the configured model before forwarding upstream. Use this endpoint when inference should stay local to the host for privacy and security reasons. External providers that should be reached directly belong in network_policies instead. Verify the Endpoint from a Sandbox openshell inference set and openshell inference update save immediately by default. Add --verify when you want the gateway to probe the resolved upstream endpoint before persisting the configuration. --no-verify is also accepted and is currently equivalent to the default; it exists so automation can opt out explicitly before a future default switch. openshell inference get confirms the current saved configuration. To confirm end-to-end connectivity from a sandbox, run: curl https://inference.local/v1/responses\nH \"Content-Type: application/json\"\nd\ninstructions\": \"You are a helpful assistant\ninput\": \"Hello\nA successful response confirms the privacy router can reach the configured backend and the model is serving requests. Gateway-scoped — every sandbox on the active gateway sees the same inference.local backend. HTTPS only — inference.local is intercepted only for HTTPS traffic. Next Steps Explore related topics: To understand the inference routing flow and supported API patterns, refer to index . To control external endpoints, refer to Network Access Rules . To manage provider records, refer to ../sandboxes/providers","format":"text","summary":"This page covers the managed local inference endpoint (https://inference.local). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details.","headings":[{"text":"Configure Inference Routing","level":1},{"text":"Step 1: Create a Provider","level":2},{"text":"Step 2: Set Inference Routing","level":2},{"text":"Step 3: Verify the Active Config","level":2},{"text":"Step 4: Update Part of the Config","level":2},{"text":"Use It from a Sandbox","level":2},{"text":"Verify the Endpoint from a Sandbox","level":3},{"text":"Next Steps","level":2}]} \ No newline at end of file +{"id":"inference/configure","title":"Configure Inference Routing","url":"inference/configure.html","last_modified":"2026-03-14T00:20:51.630573+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Set up the managed local inference endpoint with provider credentials and model configuration.","tags":["Inference Routing","Configuration","Privacy","LLM","Provider"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Configure Inference Routing This page covers the managed local inference endpoint ( https://inference.local ). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details. The configuration consists of two values: Value Description Provider record The credential backend OpenShell uses to authenticate with the upstream model host. Model ID The model to use for generation requests. Step 1: Create a Provider Create a provider that holds the backend credentials you want OpenShell to use. NVIDIA API Catalog $ openshell provider create --name nvidia-prod --type nvidia --from-existing\nThis reads NVIDIA_API_KEY from your environment. Local / self-hosted endpoint $ openshell provider create\nname my-local-model\ntype openai\ncredential OPENAI_API_KEY=empty-if-not-required\nconfig OPENAI_BASE_URL=http://192.168.10.15/v1\nUse --config OPENAI_BASE_URL to point to any OpenAI-compatible server running on your network. Set OPENAI_API_KEY to a dummy value if the server does not require authentication. Anthropic $ openshell provider create --name anthropic-prod --type anthropic --from-existing\nThis reads ANTHROPIC_API_KEY from your environment. Step 2: Set Inference Routing Point inference.local at that provider and choose the model to use: $ openshell inference set\nprovider nvidia-prod\nmodel nvidia/nemotron-3-nano-30b-a3b\nStep 3: Verify the Active Config Confirm that the provider and model are set correctly: $ openshell inference get\nGateway inference\nProvider: nvidia-prod\nModel: nvidia/nemotron-3-nano-30b-a3b\nVersion: 1\nStep 4: Update Part of the Config Use update when you want to change only one field: $ openshell inference update --model nvidia/nemotron-3-nano-30b-a3b\nOr switch providers without repeating the current model: $ openshell inference update --provider openai-prod\nUse It from a Sandbox After inference is configured, code inside any sandbox can call https://inference.local directly: from openai import OpenAI\nclient = OpenAI(base_url=\"https://inference.local/v1\", api_key=\"dummy\nresponse = client.chat.completions.create\nmodel=\"anything\nmessages=[{\"role\": \"user\", \"content\": \"Hello\nThe client-supplied model is ignored for generation requests. OpenShell rewrites it to the configured model before forwarding upstream. Use this endpoint when inference should stay local to the host for privacy and security reasons. External providers that should be reached directly belong in network_policies instead. Verify the Endpoint from a Sandbox openshell inference set and openshell inference update save immediately by default. Add --verify when you want the gateway to probe the resolved upstream endpoint before persisting the configuration. --no-verify is also accepted and is currently equivalent to the default; it exists so automation can opt out explicitly before a future default switch. openshell inference get confirms the current saved configuration. To confirm end-to-end connectivity from a sandbox, run: curl https://inference.local/v1/responses\nH \"Content-Type: application/json\"\nd\ninstructions\": \"You are a helpful assistant\ninput\": \"Hello\nA successful response confirms the privacy router can reach the configured backend and the model is serving requests. Gateway-scoped — every sandbox on the active gateway sees the same inference.local backend. HTTPS only — inference.local is intercepted only for HTTPS traffic. Next Steps Explore related topics: To understand the inference routing flow and supported API patterns, refer to index . To control external endpoints, refer to Network Access Rules . To manage provider records, refer to ../sandboxes/providers","format":"text","summary":"This page covers the managed local inference endpoint (https://inference.local). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details.","headings":[{"text":"Configure Inference Routing","level":1},{"text":"Step 1: Create a Provider","level":2},{"text":"Step 2: Set Inference Routing","level":2},{"text":"Step 3: Verify the Active Config","level":2},{"text":"Step 4: Update Part of the Config","level":2},{"text":"Use It from a Sandbox","level":2},{"text":"Verify the Endpoint from a Sandbox","level":3},{"text":"Next Steps","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/inference/index.json b/pr-preview/pr-291/inference/index.json index 10d36ede7..3b9a5e4cf 100644 --- a/pr-preview/pr-291/inference/index.json +++ b/pr-preview/pr-291/inference/index.json @@ -1 +1 @@ -{"id":"inference/index","title":"About Inference Routing","url":"inference/index.html","last_modified":"2026-03-14T00:12:41.718796+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Understand how OpenShell routes inference traffic through external endpoints and the local privacy router.","tags":["Inference Routing","Privacy","AI Agents","LLM"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"About Inference Routing NVIDIA OpenShell handles inference traffic through two endpoints: inference.local and external endpoints\nThe following table summarizes how OpenShell handles inference traffic. Path How It Works External endpoints Traffic to hosts like api.openai.com or api.anthropic.com is treated like any other outbound request — allowed or denied by network_policies . Refer to Network Access Rules . inference.local A special endpoint exposed inside every sandbox for inference that should stay local to the host for privacy and security. The privacy router strips the original credentials, injects the configured backend credentials, and forwards to the managed model endpoint. How inference.local Works When code inside a sandbox calls https://inference.local , the privacy router routes the request to the configured backend for that gateway. The configured model is applied to generation requests, and provider credentials are supplied by OpenShell rather than by code inside the sandbox. If code calls an external inference host directly, that traffic is evaluated only by network_policies . Property Detail Credentials No sandbox API keys needed — credentials come from the configured provider record. Configuration One provider and one model define sandbox inference. Provider support OpenAI, Anthropic, and NVIDIA providers all work through the same endpoint. Hot-refresh Provider credential changes and inference updates are picked up without recreating sandboxes. Supported API Patterns Supported request patterns depend on the provider configured for inference.local . OpenAI-compatible Pattern Method Path Chat Completions POST /v1/chat/completions Completions POST /v1/completions Responses POST /v1/responses Model Discovery GET /v1/models Model Discovery GET /v1/models/* Anthropic-compatible Pattern Method Path Messages POST /v1/messages Requests to inference.local that do not match the configured provider’s supported patterns are denied. Next Steps Continue with one of the following: To set up the backend behind inference.local , refer to configure . To control external endpoints, refer to Network Access Rules","format":"text","summary":"NVIDIA OpenShell handles inference traffic through two endpoints: inference.local and external endpoints. The following table summarizes how OpenShell handles inference traffic.","headings":[{"text":"About Inference Routing","level":1},{"text":"How inference.local Works","level":2},{"text":"Supported API Patterns","level":2},{"text":"Next Steps","level":2}],"children":[{"id":"inference/configure","title":"Configure Inference Routing","url":"inference/configure.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Set up the managed local inference endpoint with provider credentials and model configuration.","tags":["Inference Routing","Configuration","Privacy","LLM","Provider"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Configure Inference Routing This page covers the managed local inference endpoint ( https://inference.local ). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details. The configuration consists of two values: Value Description Provider record The credential backend OpenShell uses to authenticate with the upstream model host. Model ID The model to use for generation requests. Step 1: Create a Provider Create a provider that holds the backend credentials you want OpenShell to use. NVIDIA API Catalog $ openshell provider create --name nvidia-prod --type nvidia --from-existing\nThis reads NVIDIA_API_KEY from your environment. Local / self-hosted endpoint $ openshell provider create\nname my-local-model\ntype openai\ncredential OPENAI_API_KEY=empty-if-not-required\nconfig OPENAI_BASE_URL=http://192.168.10.15/v1\nUse --config OPENAI_BASE_URL to point to any OpenAI-compatible server running on your network. Set OPENAI_API_KEY to a dummy value if the server does not require authentication. Anthropic $ openshell provider create --name anthropic-prod --type anthropic --from-existing\nThis reads ANTHROPIC_API_KEY from your environment. Step 2: Set Inference Routing Point inference.local at that provider and choose the model to use: $ openshell inference set\nprovider nvidia-prod\nmodel nvidia/nemotron-3-nano-30b-a3b\nStep 3: Verify the Active Config Confirm that the provider and model are set correctly: $ openshell inference get\nGateway inference\nProvider: nvidia-prod\nModel: nvidia/nemotron-3-nano-30b-a3b\nVersion: 1\nStep 4: Update Part of the Config Use update when you want to change only one field: $ openshell inference update --model nvidia/nemotron-3-nano-30b-a3b\nOr switch providers without repeating the current model: $ openshell inference update --provider openai-prod\nUse It from a Sandbox After inference is configured, code inside any sandbox can call https://inference.local directly: from openai import OpenAI\nclient = OpenAI(base_url=\"https://inference.local/v1\", api_key=\"dummy\nresponse = client.chat.completions.create\nmodel=\"anything\nmessages=[{\"role\": \"user\", \"content\": \"Hello\nThe client-supplied model is ignored for generation requests. OpenShell rewrites it to the configured model before forwarding upstream. Use this endpoint when inference should stay local to the host for privacy and security reasons. External providers that should be reached directly belong in network_policies instead. Verify the Endpoint from a Sandbox openshell inference set and openshell inference update save immediately by default. Add --verify when you want the gateway to probe the resolved upstream endpoint before persisting the configuration. --no-verify is also accepted and is currently equivalent to the default; it exists so automation can opt out explicitly before a future default switch. openshell inference get confirms the current saved configuration. To confirm end-to-end connectivity from a sandbox, run: curl https://inference.local/v1/responses\nH \"Content-Type: application/json\"\nd\ninstructions\": \"You are a helpful assistant\ninput\": \"Hello\nA successful response confirms the privacy router can reach the configured backend and the model is serving requests. Gateway-scoped — every sandbox on the active gateway sees the same inference.local backend. HTTPS only — inference.local is intercepted only for HTTPS traffic. Next Steps Explore related topics: To understand the inference routing flow and supported API patterns, refer to index . To control external endpoints, refer to Network Access Rules . To manage provider records, refer to ../sandboxes/providers","format":"text","content_length":3644,"word_count":485,"summary":"This page covers the managed local inference endpoint (https://inference.local). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details.","headings":[{"text":"Configure Inference Routing","level":1,"id":"configure-inference-routing"},{"text":"Step 1: Create a Provider","level":2,"id":"step-1-create-a-provider"},{"text":"Step 2: Set Inference Routing","level":2,"id":"step-2-set-inference-routing"},{"text":"Step 3: Verify the Active Config","level":2,"id":"step-3-verify-the-active-config"},{"text":"Step 4: Update Part of the Config","level":2,"id":"step-4-update-part-of-the-config"},{"text":"Use It from a Sandbox","level":2,"id":"use-it-from-a-sandbox"},{"text":"Verify the Endpoint from a Sandbox","level":3,"id":"verify-the-endpoint-from-a-sandbox"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Configure Inference Routing Step 1: Create a Provider Step 2: Set Inference Routing Step 3: Verify the Active Config Step 4: Update Part of the Config Use It from a Sandbox Verify the Endpoint from a Sandbox Next Steps","keywords":["access","active","add","after","anthropic","api_key","base_url","catalog","chat","client","config","configure","confirm","content","correctly","create","description","directly","endpoint","explore","external","field","from","gateway","hello","http","https","inference","local","messages","model","network","next","openai","openshell","part","point","provider","response","routing","rules","run","sandbox","set","step","steps","this","topics","type","update"],"code_blocks":[{"content":"$ openshell provider create --name nvidia-prod --type nvidia --from-existing","language":"text"},{"content":"$ openshell provider create \\\n --name my-local-model \\\n --type openai \\\n --credential OPENAI_API_KEY=empty-if-not-required \\\n --config OPENAI_BASE_URL=http://192.168.10.15/v1","language":"text"},{"content":"$ openshell provider create --name anthropic-prod --type anthropic --from-existing","language":"text"},{"content":"$ openshell inference set \\\n --provider nvidia-prod \\\n --model nvidia/nemotron-3-nano-30b-a3b","language":"text"},{"content":"$ openshell inference get\nGateway inference:\n\n Provider: nvidia-prod\n Model: nvidia/nemotron-3-nano-30b-a3b\n Version: 1","language":"text"},{"content":"$ openshell inference update --model nvidia/nemotron-3-nano-30b-a3b","language":"text"},{"content":"$ openshell inference update --provider openai-prod","language":"text"},{"content":"from openai import OpenAI\n\nclient = OpenAI(base_url=\"https://inference.local/v1\", api_key=\"dummy\")\n\nresponse = client.chat.completions.create(\n model=\"anything\",\n messages=[{\"role\": \"user\", \"content\": \"Hello\"}],\n)","language":"text"},{"content":"curl https://inference.local/v1/responses \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"instructions\": \"You are a helpful assistant.\",\n \"input\": \"Hello!\"\n }'","language":"text"}],"links":[],"images":[],"doc_type":"tutorial","section_path":["Inference","Configure"]}]} \ No newline at end of file +{"id":"inference/index","title":"About Inference Routing","url":"inference/index.html","last_modified":"2026-03-14T00:20:51.634232+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Understand how OpenShell routes inference traffic through external endpoints and the local privacy router.","tags":["Inference Routing","Privacy","AI Agents","LLM"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"About Inference Routing NVIDIA OpenShell handles inference traffic through two endpoints: inference.local and external endpoints\nThe following table summarizes how OpenShell handles inference traffic. Path How It Works External endpoints Traffic to hosts like api.openai.com or api.anthropic.com is treated like any other outbound request — allowed or denied by network_policies . Refer to Network Access Rules . inference.local A special endpoint exposed inside every sandbox for inference that should stay local to the host for privacy and security. The privacy router strips the original credentials, injects the configured backend credentials, and forwards to the managed model endpoint. How inference.local Works When code inside a sandbox calls https://inference.local , the privacy router routes the request to the configured backend for that gateway. The configured model is applied to generation requests, and provider credentials are supplied by OpenShell rather than by code inside the sandbox. If code calls an external inference host directly, that traffic is evaluated only by network_policies . Property Detail Credentials No sandbox API keys needed — credentials come from the configured provider record. Configuration One provider and one model define sandbox inference. Provider support OpenAI, Anthropic, and NVIDIA providers all work through the same endpoint. Hot-refresh Provider credential changes and inference updates are picked up without recreating sandboxes. Supported API Patterns Supported request patterns depend on the provider configured for inference.local . OpenAI-compatible Pattern Method Path Chat Completions POST /v1/chat/completions Completions POST /v1/completions Responses POST /v1/responses Model Discovery GET /v1/models Model Discovery GET /v1/models/* Anthropic-compatible Pattern Method Path Messages POST /v1/messages Requests to inference.local that do not match the configured provider’s supported patterns are denied. Next Steps Continue with one of the following: To set up the backend behind inference.local , refer to configure . To control external endpoints, refer to Network Access Rules","format":"text","summary":"NVIDIA OpenShell handles inference traffic through two endpoints: inference.local and external endpoints. The following table summarizes how OpenShell handles inference traffic.","headings":[{"text":"About Inference Routing","level":1},{"text":"How inference.local Works","level":2},{"text":"Supported API Patterns","level":2},{"text":"Next Steps","level":2}],"children":[{"id":"inference/configure","title":"Configure Inference Routing","url":"inference/configure.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Set up the managed local inference endpoint with provider credentials and model configuration.","tags":["Inference Routing","Configuration","Privacy","LLM","Provider"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Configure Inference Routing This page covers the managed local inference endpoint ( https://inference.local ). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details. The configuration consists of two values: Value Description Provider record The credential backend OpenShell uses to authenticate with the upstream model host. Model ID The model to use for generation requests. Step 1: Create a Provider Create a provider that holds the backend credentials you want OpenShell to use. NVIDIA API Catalog $ openshell provider create --name nvidia-prod --type nvidia --from-existing\nThis reads NVIDIA_API_KEY from your environment. Local / self-hosted endpoint $ openshell provider create\nname my-local-model\ntype openai\ncredential OPENAI_API_KEY=empty-if-not-required\nconfig OPENAI_BASE_URL=http://192.168.10.15/v1\nUse --config OPENAI_BASE_URL to point to any OpenAI-compatible server running on your network. Set OPENAI_API_KEY to a dummy value if the server does not require authentication. Anthropic $ openshell provider create --name anthropic-prod --type anthropic --from-existing\nThis reads ANTHROPIC_API_KEY from your environment. Step 2: Set Inference Routing Point inference.local at that provider and choose the model to use: $ openshell inference set\nprovider nvidia-prod\nmodel nvidia/nemotron-3-nano-30b-a3b\nStep 3: Verify the Active Config Confirm that the provider and model are set correctly: $ openshell inference get\nGateway inference\nProvider: nvidia-prod\nModel: nvidia/nemotron-3-nano-30b-a3b\nVersion: 1\nStep 4: Update Part of the Config Use update when you want to change only one field: $ openshell inference update --model nvidia/nemotron-3-nano-30b-a3b\nOr switch providers without repeating the current model: $ openshell inference update --provider openai-prod\nUse It from a Sandbox After inference is configured, code inside any sandbox can call https://inference.local directly: from openai import OpenAI\nclient = OpenAI(base_url=\"https://inference.local/v1\", api_key=\"dummy\nresponse = client.chat.completions.create\nmodel=\"anything\nmessages=[{\"role\": \"user\", \"content\": \"Hello\nThe client-supplied model is ignored for generation requests. OpenShell rewrites it to the configured model before forwarding upstream. Use this endpoint when inference should stay local to the host for privacy and security reasons. External providers that should be reached directly belong in network_policies instead. Verify the Endpoint from a Sandbox openshell inference set and openshell inference update save immediately by default. Add --verify when you want the gateway to probe the resolved upstream endpoint before persisting the configuration. --no-verify is also accepted and is currently equivalent to the default; it exists so automation can opt out explicitly before a future default switch. openshell inference get confirms the current saved configuration. To confirm end-to-end connectivity from a sandbox, run: curl https://inference.local/v1/responses\nH \"Content-Type: application/json\"\nd\ninstructions\": \"You are a helpful assistant\ninput\": \"Hello\nA successful response confirms the privacy router can reach the configured backend and the model is serving requests. Gateway-scoped — every sandbox on the active gateway sees the same inference.local backend. HTTPS only — inference.local is intercepted only for HTTPS traffic. Next Steps Explore related topics: To understand the inference routing flow and supported API patterns, refer to index . To control external endpoints, refer to Network Access Rules . To manage provider records, refer to ../sandboxes/providers","format":"text","content_length":3644,"word_count":485,"summary":"This page covers the managed local inference endpoint (https://inference.local). External inference endpoints go through sandbox network_policies — refer to Network Access Rules for details.","headings":[{"text":"Configure Inference Routing","level":1,"id":"configure-inference-routing"},{"text":"Step 1: Create a Provider","level":2,"id":"step-1-create-a-provider"},{"text":"Step 2: Set Inference Routing","level":2,"id":"step-2-set-inference-routing"},{"text":"Step 3: Verify the Active Config","level":2,"id":"step-3-verify-the-active-config"},{"text":"Step 4: Update Part of the Config","level":2,"id":"step-4-update-part-of-the-config"},{"text":"Use It from a Sandbox","level":2,"id":"use-it-from-a-sandbox"},{"text":"Verify the Endpoint from a Sandbox","level":3,"id":"verify-the-endpoint-from-a-sandbox"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Configure Inference Routing Step 1: Create a Provider Step 2: Set Inference Routing Step 3: Verify the Active Config Step 4: Update Part of the Config Use It from a Sandbox Verify the Endpoint from a Sandbox Next Steps","keywords":["access","active","add","after","anthropic","api_key","base_url","catalog","chat","client","config","configure","confirm","content","correctly","create","description","directly","endpoint","explore","external","field","from","gateway","hello","http","https","inference","local","messages","model","network","next","openai","openshell","part","point","provider","response","routing","rules","run","sandbox","set","step","steps","this","topics","type","update"],"code_blocks":[{"content":"$ openshell provider create --name nvidia-prod --type nvidia --from-existing","language":"text"},{"content":"$ openshell provider create \\\n --name my-local-model \\\n --type openai \\\n --credential OPENAI_API_KEY=empty-if-not-required \\\n --config OPENAI_BASE_URL=http://192.168.10.15/v1","language":"text"},{"content":"$ openshell provider create --name anthropic-prod --type anthropic --from-existing","language":"text"},{"content":"$ openshell inference set \\\n --provider nvidia-prod \\\n --model nvidia/nemotron-3-nano-30b-a3b","language":"text"},{"content":"$ openshell inference get\nGateway inference:\n\n Provider: nvidia-prod\n Model: nvidia/nemotron-3-nano-30b-a3b\n Version: 1","language":"text"},{"content":"$ openshell inference update --model nvidia/nemotron-3-nano-30b-a3b","language":"text"},{"content":"$ openshell inference update --provider openai-prod","language":"text"},{"content":"from openai import OpenAI\n\nclient = OpenAI(base_url=\"https://inference.local/v1\", api_key=\"dummy\")\n\nresponse = client.chat.completions.create(\n model=\"anything\",\n messages=[{\"role\": \"user\", \"content\": \"Hello\"}],\n)","language":"text"},{"content":"curl https://inference.local/v1/responses \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"instructions\": \"You are a helpful assistant.\",\n \"input\": \"Hello!\"\n }'","language":"text"}],"links":[],"images":[],"doc_type":"tutorial","section_path":["Inference","Configure"]}]} \ No newline at end of file diff --git a/pr-preview/pr-291/reference/default-policy.json b/pr-preview/pr-291/reference/default-policy.json index 6a34df7e1..166426bfb 100644 --- a/pr-preview/pr-291/reference/default-policy.json +++ b/pr-preview/pr-291/reference/default-policy.json @@ -1 +1 @@ -{"id":"reference/default-policy","title":"Default Policy Reference","url":"reference/default-policy.html","last_modified":"2026-03-14T00:12:41.720508+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Breakdown of the built-in default policy applied when you create an OpenShell sandbox without a custom policy.","tags":["ai_agents","sandboxing","security","policy"],"topics":["generative_ai","cybersecurity"],"content_type":"reference","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"keywords":["openshell default policy","sandbox policy","agent compatibility"],"content":"Default Policy Reference The default policy is the policy applied when you create an OpenShell sandbox without --policy . It is baked into the community base image ( ghcr.io/nvidia/openshell-community/sandboxes/base ) and defined in the community repo’s dev-sandbox-policy.yaml . Agent Compatibility The following table shows the coverage of the default policy for common agents. Agent Coverage Action Required Claude Code Full None. Works out of the box. OpenCode Partial Add opencode.ai endpoint and OpenCode binary paths. Codex None Provide a complete custom policy with OpenAI endpoints and Codex binary paths. If you run a non-Claude agent without a custom policy, the agent’s API calls are denied by the proxy. You must provide a policy that declares the agent’s endpoints and binaries. Default Policy Blocks The default policy blocks are defined in the community base image. See the openshell-community repository for the full dev-sandbox-policy.yaml source","format":"text","summary":"The default policy is the policy applied when you create an OpenShell sandbox without --policy. It is baked into the community base image (ghcr.io/nvidia/openshell-community/sandboxes/base) and defined in the community repo’s dev-sandbox-policy.yaml.","headings":[{"text":"Default Policy Reference","level":1},{"text":"Agent Compatibility","level":2},{"text":"Default Policy Blocks","level":2}]} \ No newline at end of file +{"id":"reference/default-policy","title":"Default Policy Reference","url":"reference/default-policy.html","last_modified":"2026-03-14T00:20:51.635777+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Breakdown of the built-in default policy applied when you create an OpenShell sandbox without a custom policy.","tags":["ai_agents","sandboxing","security","policy"],"topics":["generative_ai","cybersecurity"],"content_type":"reference","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"keywords":["openshell default policy","sandbox policy","agent compatibility"],"content":"Default Policy Reference The default policy is the policy applied when you create an OpenShell sandbox without --policy . It is baked into the community base image ( ghcr.io/nvidia/openshell-community/sandboxes/base ) and defined in the community repo’s dev-sandbox-policy.yaml . Agent Compatibility The following table shows the coverage of the default policy for common agents. Agent Coverage Action Required Claude Code Full None. Works out of the box. OpenCode Partial Add opencode.ai endpoint and OpenCode binary paths. Codex None Provide a complete custom policy with OpenAI endpoints and Codex binary paths. If you run a non-Claude agent without a custom policy, the agent’s API calls are denied by the proxy. You must provide a policy that declares the agent’s endpoints and binaries. Default Policy Blocks The default policy blocks are defined in the community base image. See the openshell-community repository for the full dev-sandbox-policy.yaml source","format":"text","summary":"The default policy is the policy applied when you create an OpenShell sandbox without --policy. It is baked into the community base image (ghcr.io/nvidia/openshell-community/sandboxes/base) and defined in the community repo’s dev-sandbox-policy.yaml.","headings":[{"text":"Default Policy Reference","level":1},{"text":"Agent Compatibility","level":2},{"text":"Default Policy Blocks","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/reference/policy-schema.json b/pr-preview/pr-291/reference/policy-schema.json index 4589f9053..e7cc453da 100644 --- a/pr-preview/pr-291/reference/policy-schema.json +++ b/pr-preview/pr-291/reference/policy-schema.json @@ -1 +1 @@ -{"id":"reference/policy-schema","title":"Policy Schema Reference","url":"reference/policy-schema.html","last_modified":"2026-03-14T00:12:41.733954+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Complete field reference for the sandbox policy YAML including static and dynamic sections.","tags":["Policy","Schema","YAML","Reference","Security"],"topics":["Generative AI","Cybersecurity"],"content_type":"reference","learning_level":"technical_advanced","audience":["engineer"],"content":"Policy Schema Reference Complete field reference for the sandbox policy YAML. Each field is documented with its type, whether it is required, and whether it is static (locked at sandbox creation) or dynamic (hot-reloadable on a running sandbox). Top-Level Structure A policy YAML file contains the following top-level fields: version: 1\nfilesystem_policy: { ...\nlandlock: { ...\nprocess: { ...\nnetwork_policies: { ...\nField Type Required Category Description version integer Yes – Policy schema version. Must be 1 . filesystem_policy object No Static Controls which directories the agent can read and write. landlock object No Static Configures Landlock LSM enforcement behavior. process object No Static Sets the user and group the agent process runs as. network_policies map No Dynamic Declares which binaries can reach which network endpoints. Static fields are set at sandbox creation time. Changing them requires destroying and recreating the sandbox. Dynamic fields can be updated on a running sandbox with openshell policy set and take effect without restarting. Version The version field identifies which schema the policy uses: Field Type Required Description version integer Yes Schema version number. Currently must be 1 . Filesystem Policy Category: Static Controls filesystem access inside the sandbox. Paths not listed in either read_only or read_write are inaccessible. Field Type Required Description include_workdir bool No When true , automatically adds the agent’s working directory to read_write . read_only list of strings No Paths the agent can read but not modify. Typically system directories like /usr , /lib , /etc . read_write list of strings No Paths the agent can read and write. Typically /sandbox (working directory) and /tmp . Validation constraints: Every path must be absolute (start with / ). Paths must not contain .. traversal components. The server normalizes paths before storage, but rejects policies where traversal would escape the intended scope. Read-write paths must not be overly broad (for example, / alone is rejected). Each individual path must not exceed 4096 characters. The combined total of read_only and read_write paths must not exceed 256. Policies that violate these constraints are rejected with INVALID_ARGUMENT at creation or update time. Disk-loaded YAML policies that fail validation fall back to a restrictive default. Example: filesystem_policy\ninclude_workdir: true\nread_only\n/usr\n/lib\n/proc\n/dev/urandom\n/etc\nread_write\n/sandbox\n/tmp\n/dev/null\nLandlock Category: Static Configures Landlock LSM enforcement at the kernel level. Landlock provides mandatory filesystem access control below what UNIX permissions allow. Field Type Required Values Description compatibility string No best_effort , hard_requirement How OpenShell handles kernel ABI differences. best_effort uses the highest Landlock ABI the host kernel supports. hard_requirement fails if the required ABI is unavailable. Example: landlock\ncompatibility: best_effort\nProcess Category: Static Sets the OS-level identity for the agent process inside the sandbox. Field Type Required Description run_as_user string No The user name or UID the agent process runs as. Default: sandbox . run_as_group string No The group name or GID the agent process runs as. Default: sandbox . Validation constraint: Neither run_as_user nor run_as_group may be set to root or 0 . Policies that request root process identity are rejected at creation or update time. Example: process\nrun_as_user: sandbox\nrun_as_group: sandbox\nNetwork Policies Category: Dynamic A map of named network policy entries. Each entry declares a set of endpoints and a set of binaries. Only the listed binaries are permitted to connect to the listed endpoints. The map key is a logical identifier. The name field inside the entry is the display name used in logs. Network Policy Entry Each entry in the network_policies map has the following fields: Field Type Required Description name string No Display name for the policy entry. Used in log output. Defaults to the map key. endpoints list of endpoint objects Yes Hosts and ports this entry permits. binaries list of binary objects Yes Executables allowed to connect to these endpoints. Endpoint Object Each endpoint defines a reachable destination and optional inspection rules. Field Type Required Description host string Yes Hostname or IP address. Supports wildcards: *.example.com matches any subdomain. port integer Yes TCP port number. protocol string No Set to rest to enable HTTP request inspection. Omit for TCP passthrough. tls string No TLS handling mode. terminate decrypts TLS at the proxy for inspection. passthrough forwards encrypted traffic without inspection. Only relevant when protocol is rest . enforcement string No enforce actively blocks disallowed requests. audit logs violations but allows traffic through. access string No HTTP access level. One of read-only , read-write , or full . Mutually exclusive with rules . rules list of rule objects No Fine-grained per-method, per-path allow rules. Mutually exclusive with access . Access Levels The access field accepts one of the following values: Value Allowed HTTP Methods full All methods and paths. read-only GET , HEAD , OPTIONS . read-write GET , HEAD , OPTIONS , POST , PUT , PATCH . Rule Object Used when access is not set. Each rule explicitly allows a method and path combination. Field Type Required Description allow.method string Yes HTTP method to allow (for example, GET , POST ). allow.path string Yes URL path pattern. Supports * and ** glob syntax. Example with rules: rules\nallow\nmethod: GET\npath: /**/info/refs\nallow\nmethod: POST\npath: /**/git-upload-pack\nBinary Object Identifies an executable that is permitted to use the associated endpoints. Field Type Required Description path string Yes Filesystem path to the executable. Supports glob patterns with * and ** . For example, /sandbox/.vscode-server/** matches any executable under that directory tree. Full Example The following policy grants read-only GitHub API access and npm registry access: network_policies\ngithub_rest_api\nname: github-rest-api\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\naccess: read-only\nbinaries\npath: /usr/local/bin/claude\npath: /usr/bin/node\npath: /usr/bin/gh\nnpm_registry\nname: npm-registry\nendpoints\nhost: registry.npmjs.org\nport: 443\nbinaries\npath: /usr/bin/npm\npath: /usr/bin/node","format":"text","summary":"Complete field reference for the sandbox policy YAML. Each field is documented with its type, whether it is required, and whether it is static (locked at sandbox creation) or dynamic (hot-reloadable on a running sandbox).","headings":[{"text":"Policy Schema Reference","level":1},{"text":"Top-Level Structure","level":2},{"text":"Version","level":2},{"text":"Filesystem Policy","level":2},{"text":"Landlock","level":2},{"text":"Process","level":2},{"text":"Network Policies","level":2},{"text":"Network Policy Entry","level":3},{"text":"Endpoint Object","level":3},{"text":"Access Levels","level":4},{"text":"Rule Object","level":4},{"text":"Binary Object","level":3},{"text":"Full Example","level":3}]} \ No newline at end of file +{"id":"reference/policy-schema","title":"Policy Schema Reference","url":"reference/policy-schema.html","last_modified":"2026-03-14T00:20:51.649004+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Complete field reference for the sandbox policy YAML including static and dynamic sections.","tags":["Policy","Schema","YAML","Reference","Security"],"topics":["Generative AI","Cybersecurity"],"content_type":"reference","learning_level":"technical_advanced","audience":["engineer"],"content":"Policy Schema Reference Complete field reference for the sandbox policy YAML. Each field is documented with its type, whether it is required, and whether it is static (locked at sandbox creation) or dynamic (hot-reloadable on a running sandbox). Top-Level Structure A policy YAML file contains the following top-level fields: version: 1\nfilesystem_policy: { ...\nlandlock: { ...\nprocess: { ...\nnetwork_policies: { ...\nField Type Required Category Description version integer Yes – Policy schema version. Must be 1 . filesystem_policy object No Static Controls which directories the agent can read and write. landlock object No Static Configures Landlock LSM enforcement behavior. process object No Static Sets the user and group the agent process runs as. network_policies map No Dynamic Declares which binaries can reach which network endpoints. Static fields are set at sandbox creation time. Changing them requires destroying and recreating the sandbox. Dynamic fields can be updated on a running sandbox with openshell policy set and take effect without restarting. Version The version field identifies which schema the policy uses: Field Type Required Description version integer Yes Schema version number. Currently must be 1 . Filesystem Policy Category: Static Controls filesystem access inside the sandbox. Paths not listed in either read_only or read_write are inaccessible. Field Type Required Description include_workdir bool No When true , automatically adds the agent’s working directory to read_write . read_only list of strings No Paths the agent can read but not modify. Typically system directories like /usr , /lib , /etc . read_write list of strings No Paths the agent can read and write. Typically /sandbox (working directory) and /tmp . Validation constraints: Every path must be absolute (start with / ). Paths must not contain .. traversal components. The server normalizes paths before storage, but rejects policies where traversal would escape the intended scope. Read-write paths must not be overly broad (for example, / alone is rejected). Each individual path must not exceed 4096 characters. The combined total of read_only and read_write paths must not exceed 256. Policies that violate these constraints are rejected with INVALID_ARGUMENT at creation or update time. Disk-loaded YAML policies that fail validation fall back to a restrictive default. Example: filesystem_policy\ninclude_workdir: true\nread_only\n/usr\n/lib\n/proc\n/dev/urandom\n/etc\nread_write\n/sandbox\n/tmp\n/dev/null\nLandlock Category: Static Configures Landlock LSM enforcement at the kernel level. Landlock provides mandatory filesystem access control below what UNIX permissions allow. Field Type Required Values Description compatibility string No best_effort , hard_requirement How OpenShell handles kernel ABI differences. best_effort uses the highest Landlock ABI the host kernel supports. hard_requirement fails if the required ABI is unavailable. Example: landlock\ncompatibility: best_effort\nProcess Category: Static Sets the OS-level identity for the agent process inside the sandbox. Field Type Required Description run_as_user string No The user name or UID the agent process runs as. Default: sandbox . run_as_group string No The group name or GID the agent process runs as. Default: sandbox . Validation constraint: Neither run_as_user nor run_as_group may be set to root or 0 . Policies that request root process identity are rejected at creation or update time. Example: process\nrun_as_user: sandbox\nrun_as_group: sandbox\nNetwork Policies Category: Dynamic A map of named network policy entries. Each entry declares a set of endpoints and a set of binaries. Only the listed binaries are permitted to connect to the listed endpoints. The map key is a logical identifier. The name field inside the entry is the display name used in logs. Network Policy Entry Each entry in the network_policies map has the following fields: Field Type Required Description name string No Display name for the policy entry. Used in log output. Defaults to the map key. endpoints list of endpoint objects Yes Hosts and ports this entry permits. binaries list of binary objects Yes Executables allowed to connect to these endpoints. Endpoint Object Each endpoint defines a reachable destination and optional inspection rules. Field Type Required Description host string Yes Hostname or IP address. Supports wildcards: *.example.com matches any subdomain. port integer Yes TCP port number. protocol string No Set to rest to enable HTTP request inspection. Omit for TCP passthrough. tls string No TLS handling mode. terminate decrypts TLS at the proxy for inspection. passthrough forwards encrypted traffic without inspection. Only relevant when protocol is rest . enforcement string No enforce actively blocks disallowed requests. audit logs violations but allows traffic through. access string No HTTP access level. One of read-only , read-write , or full . Mutually exclusive with rules . rules list of rule objects No Fine-grained per-method, per-path allow rules. Mutually exclusive with access . Access Levels The access field accepts one of the following values: Value Allowed HTTP Methods full All methods and paths. read-only GET , HEAD , OPTIONS . read-write GET , HEAD , OPTIONS , POST , PUT , PATCH . Rule Object Used when access is not set. Each rule explicitly allows a method and path combination. Field Type Required Description allow.method string Yes HTTP method to allow (for example, GET , POST ). allow.path string Yes URL path pattern. Supports * and ** glob syntax. Example with rules: rules\nallow\nmethod: GET\npath: /**/info/refs\nallow\nmethod: POST\npath: /**/git-upload-pack\nBinary Object Identifies an executable that is permitted to use the associated endpoints. Field Type Required Description path string Yes Filesystem path to the executable. Supports glob patterns with * and ** . For example, /sandbox/.vscode-server/** matches any executable under that directory tree. Full Example The following policy grants read-only GitHub API access and npm registry access: network_policies\ngithub_rest_api\nname: github-rest-api\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\naccess: read-only\nbinaries\npath: /usr/local/bin/claude\npath: /usr/bin/node\npath: /usr/bin/gh\nnpm_registry\nname: npm-registry\nendpoints\nhost: registry.npmjs.org\nport: 443\nbinaries\npath: /usr/bin/npm\npath: /usr/bin/node","format":"text","summary":"Complete field reference for the sandbox policy YAML. Each field is documented with its type, whether it is required, and whether it is static (locked at sandbox creation) or dynamic (hot-reloadable on a running sandbox).","headings":[{"text":"Policy Schema Reference","level":1},{"text":"Top-Level Structure","level":2},{"text":"Version","level":2},{"text":"Filesystem Policy","level":2},{"text":"Landlock","level":2},{"text":"Process","level":2},{"text":"Network Policies","level":2},{"text":"Network Policy Entry","level":3},{"text":"Endpoint Object","level":3},{"text":"Access Levels","level":4},{"text":"Rule Object","level":4},{"text":"Binary Object","level":3},{"text":"Full Example","level":3}]} \ No newline at end of file diff --git a/pr-preview/pr-291/reference/support-matrix.json b/pr-preview/pr-291/reference/support-matrix.json index 045a517f2..49b9ac233 100644 --- a/pr-preview/pr-291/reference/support-matrix.json +++ b/pr-preview/pr-291/reference/support-matrix.json @@ -1 +1 @@ -{"id":"reference/support-matrix","title":"Support Matrix","url":"reference/support-matrix.html","last_modified":"2026-03-14T00:12:41.737505+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"content":"Support Matrix This page lists the platform, software, runtime, and kernel requirements for running OpenShell. Supported Platforms OpenShell publishes multi-architecture container images for linux/amd64 and linux/arm64 . The CLI is supported on the following host platforms: Platform Architecture Status Linux (Debian/Ubuntu) x86_64 (amd64) Supported Linux (Debian/Ubuntu) aarch64 (arm64) Supported macOS (Docker Desktop) Apple Silicon (arm64) Supported Windows (WSL 2 + Docker Desktop) x86_64 Untested Software Prerequisites The following software must be installed on the host before using the OpenShell CLI: Component Minimum Version Notes Docker Desktop or Docker Engine 28.04 Must be running before any openshell command. Sandbox Runtime Versions Sandbox container images are maintained in the openshell-community repository. Refer to that repository for the current list of installed components and their versions. Container Images OpenShell publishes two container images. Both are published for linux/amd64 and linux/arm64 . Image Reference Pulled When Cluster ghcr.io/nvidia/openshell/cluster:latest openshell gateway start Gateway ghcr.io/nvidia/openshell/gateway:latest Cluster startup (via Helm chart) The cluster image bundles the Helm charts, Kubernetes manifests, and the openshell-sandbox supervisor binary required to bootstrap the control plane. The supervisor binary is side-loaded into sandbox pods at runtime via a read-only host volume mount. The gateway image is pulled at cluster startup and runs the API server. Sandbox images are maintained separately in the openshell-community repository. To override the default image references, set the following environment variables: Variable Purpose OPENSHELL_CLUSTER_IMAGE Override the cluster image reference. OPENSHELL_COMMUNITY_REGISTRY Override the registry for community sandbox images. Kernel Requirements OpenShell enforces sandbox isolation through two Linux kernel security modules: Module Requirement Details Landlock LSM Recommended Enforces filesystem access restrictions at the kernel level. The best_effort compatibility mode uses the highest Landlock ABI the host kernel supports. The hard_requirement mode fails sandbox creation if the required ABI is unavailable. seccomp Required Filters dangerous system calls. Available on all modern Linux kernels (3.17+). On macOS, these kernel modules run inside the Docker Desktop Linux VM, not on the host kernel. Agent Compatibility For the full list of supported agents and their default policy coverage, refer to the Supported Agents table","format":"text","summary":"This page lists the platform, software, runtime, and kernel requirements for running OpenShell.","headings":[{"text":"Support Matrix","level":1},{"text":"Supported Platforms","level":2},{"text":"Software Prerequisites","level":2},{"text":"Sandbox Runtime Versions","level":2},{"text":"Container Images","level":2},{"text":"Kernel Requirements","level":2},{"text":"Agent Compatibility","level":2}]} \ No newline at end of file +{"id":"reference/support-matrix","title":"Support Matrix","url":"reference/support-matrix.html","last_modified":"2026-03-14T00:20:51.652281+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"content":"Support Matrix This page lists the platform, software, runtime, and kernel requirements for running OpenShell. Supported Platforms OpenShell publishes multi-architecture container images for linux/amd64 and linux/arm64 . The CLI is supported on the following host platforms: Platform Architecture Status Linux (Debian/Ubuntu) x86_64 (amd64) Supported Linux (Debian/Ubuntu) aarch64 (arm64) Supported macOS (Docker Desktop) Apple Silicon (arm64) Supported Windows (WSL 2 + Docker Desktop) x86_64 Untested Software Prerequisites The following software must be installed on the host before using the OpenShell CLI: Component Minimum Version Notes Docker Desktop or Docker Engine 28.04 Must be running before any openshell command. Sandbox Runtime Versions Sandbox container images are maintained in the openshell-community repository. Refer to that repository for the current list of installed components and their versions. Container Images OpenShell publishes two container images. Both are published for linux/amd64 and linux/arm64 . Image Reference Pulled When Cluster ghcr.io/nvidia/openshell/cluster:latest openshell gateway start Gateway ghcr.io/nvidia/openshell/gateway:latest Cluster startup (via Helm chart) The cluster image bundles the Helm charts, Kubernetes manifests, and the openshell-sandbox supervisor binary required to bootstrap the control plane. The supervisor binary is side-loaded into sandbox pods at runtime via a read-only host volume mount. The gateway image is pulled at cluster startup and runs the API server. Sandbox images are maintained separately in the openshell-community repository. To override the default image references, set the following environment variables: Variable Purpose OPENSHELL_CLUSTER_IMAGE Override the cluster image reference. OPENSHELL_COMMUNITY_REGISTRY Override the registry for community sandbox images. Kernel Requirements OpenShell enforces sandbox isolation through two Linux kernel security modules: Module Requirement Details Landlock LSM Recommended Enforces filesystem access restrictions at the kernel level. The best_effort compatibility mode uses the highest Landlock ABI the host kernel supports. The hard_requirement mode fails sandbox creation if the required ABI is unavailable. seccomp Required Filters dangerous system calls. Available on all modern Linux kernels (3.17+). On macOS, these kernel modules run inside the Docker Desktop Linux VM, not on the host kernel. Agent Compatibility For the full list of supported agents and their default policy coverage, refer to the Supported Agents table","format":"text","summary":"This page lists the platform, software, runtime, and kernel requirements for running OpenShell.","headings":[{"text":"Support Matrix","level":1},{"text":"Supported Platforms","level":2},{"text":"Software Prerequisites","level":2},{"text":"Sandbox Runtime Versions","level":2},{"text":"Container Images","level":2},{"text":"Kernel Requirements","level":2},{"text":"Agent Compatibility","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/resources/eula.json b/pr-preview/pr-291/resources/eula.json index 1e547e8db..72acf3601 100644 --- a/pr-preview/pr-291/resources/eula.json +++ b/pr-preview/pr-291/resources/eula.json @@ -1 +1 @@ -{"id":"resources/eula","title":"License","url":"resources/eula.html","last_modified":"2026-03-14T00:12:41.740573+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"NVIDIA OpenShell license agreement and terms of use.","tags":["License","EULA"],"topics":["Legal"],"content_type":"reference","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"License","format":"text","summary":" License","headings":[{"text":"License","level":1}]} \ No newline at end of file +{"id":"resources/eula","title":"License","url":"resources/eula.html","last_modified":"2026-03-14T00:20:51.655606+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"NVIDIA OpenShell license agreement and terms of use.","tags":["License","EULA"],"topics":["Legal"],"content_type":"reference","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"License","format":"text","summary":" License","headings":[{"text":"License","level":1}]} \ No newline at end of file diff --git a/pr-preview/pr-291/sandboxes/community-sandboxes.json b/pr-preview/pr-291/sandboxes/community-sandboxes.json index 144f60f27..257cf5677 100644 --- a/pr-preview/pr-291/sandboxes/community-sandboxes.json +++ b/pr-preview/pr-291/sandboxes/community-sandboxes.json @@ -1 +1 @@ -{"id":"sandboxes/community-sandboxes","title":"Community Sandboxes","url":"sandboxes/community-sandboxes.html","last_modified":"2026-03-14T00:12:41.745917+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Use pre-built sandboxes from the OpenShell Community catalog or contribute your own.","tags":["Community","Sandbox","Container Image","Open Source"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Community Sandboxes Use pre-built sandboxes from the OpenShell Community catalog, or contribute your\nown. What Are Community Sandboxes Community sandboxes are ready-to-use environments published in the\nOpenShell Community repository\nEach sandbox bundles a Dockerfile, policy, optional skills, and startup scripts\ninto a single package that you can launch with one command. Current Catalog The following community sandboxes are available in the catalog. Sandbox Description base Foundational image with system tools and dev environment openclaw Open agent manipulation and control sdg Synthetic data generation workflows simulation General-purpose simulation sandboxes Use a Community Sandbox Launch a community sandbox by name with the --from flag: $ openshell sandbox create --from openclaw\nWhen you pass --from with a community sandbox name, the CLI: Resolves the name against the\nOpenShell Community repository. Pulls the Dockerfile, policy, skills, and any startup scripts. Builds the container image locally. Creates the sandbox with the bundled configuration applied. You end up with a running sandbox whose image, policy, and tooling are all\npreconfigured by the community package. Other Sources The --from flag also accepts: Local directory paths: Point to a directory on disk that contains a\nDockerfile and optional policy/skills: $ openshell sandbox create --from ./my-sandbox-dir\nContainer image references: Use an existing container image directly: $ openshell sandbox create --from my-registry.example.com/my-image:latest\nContribute a Community Sandbox Each community sandbox is a directory under sandboxes/ in the\nOpenShell Community repository\nAt minimum, a sandbox directory must contain the following files: Dockerfile that defines the container image. README.md that describes the sandbox and how to use it. You can also include the following optional files: policy.yaml that defines the default policy applied when the sandbox launches. skills/ that contains agent skill definitions bundled with the sandbox. Startup scripts that are any scripts the Dockerfile or entrypoint invokes. To contribute, fork the repository, add your sandbox directory, and open a pull\nrequest. Refer to the repository’s\nCONTRIBUTING.md\nfor submission guidelines. The community catalog is designed to grow. If you have built a sandbox that\nsupports a particular workflow (data processing, simulation, code review\nor anything else), consider contributing it back so others can use it. Next Steps Explore related topics: Need to supply API keys or tokens? Set up providers for credential management. Want to customize the sandbox policy? Write custom rules in policies","format":"text","summary":"Use pre-built sandboxes from the OpenShell Community catalog, or contribute your own.","headings":[{"text":"Community Sandboxes","level":1},{"text":"What Are Community Sandboxes","level":2},{"text":"Current Catalog","level":2},{"text":"Use a Community Sandbox","level":2},{"text":"Other Sources","level":3},{"text":"Contribute a Community Sandbox","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file +{"id":"sandboxes/community-sandboxes","title":"Community Sandboxes","url":"sandboxes/community-sandboxes.html","last_modified":"2026-03-14T00:20:51.660937+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Use pre-built sandboxes from the OpenShell Community catalog or contribute your own.","tags":["Community","Sandbox","Container Image","Open Source"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Community Sandboxes Use pre-built sandboxes from the OpenShell Community catalog, or contribute your\nown. What Are Community Sandboxes Community sandboxes are ready-to-use environments published in the\nOpenShell Community repository\nEach sandbox bundles a Dockerfile, policy, optional skills, and startup scripts\ninto a single package that you can launch with one command. Current Catalog The following community sandboxes are available in the catalog. Sandbox Description base Foundational image with system tools and dev environment openclaw Open agent manipulation and control sdg Synthetic data generation workflows simulation General-purpose simulation sandboxes Use a Community Sandbox Launch a community sandbox by name with the --from flag: $ openshell sandbox create --from openclaw\nWhen you pass --from with a community sandbox name, the CLI: Resolves the name against the\nOpenShell Community repository. Pulls the Dockerfile, policy, skills, and any startup scripts. Builds the container image locally. Creates the sandbox with the bundled configuration applied. You end up with a running sandbox whose image, policy, and tooling are all\npreconfigured by the community package. Other Sources The --from flag also accepts: Local directory paths: Point to a directory on disk that contains a\nDockerfile and optional policy/skills: $ openshell sandbox create --from ./my-sandbox-dir\nContainer image references: Use an existing container image directly: $ openshell sandbox create --from my-registry.example.com/my-image:latest\nContribute a Community Sandbox Each community sandbox is a directory under sandboxes/ in the\nOpenShell Community repository\nAt minimum, a sandbox directory must contain the following files: Dockerfile that defines the container image. README.md that describes the sandbox and how to use it. You can also include the following optional files: policy.yaml that defines the default policy applied when the sandbox launches. skills/ that contains agent skill definitions bundled with the sandbox. Startup scripts that are any scripts the Dockerfile or entrypoint invokes. To contribute, fork the repository, add your sandbox directory, and open a pull\nrequest. Refer to the repository’s\nCONTRIBUTING.md\nfor submission guidelines. The community catalog is designed to grow. If you have built a sandbox that\nsupports a particular workflow (data processing, simulation, code review\nor anything else), consider contributing it back so others can use it. Next Steps Explore related topics: Need to supply API keys or tokens? Set up providers for credential management. Want to customize the sandbox policy? Write custom rules in policies","format":"text","summary":"Use pre-built sandboxes from the OpenShell Community catalog, or contribute your own.","headings":[{"text":"Community Sandboxes","level":1},{"text":"What Are Community Sandboxes","level":2},{"text":"Current Catalog","level":2},{"text":"Use a Community Sandbox","level":2},{"text":"Other Sources","level":3},{"text":"Contribute a Community Sandbox","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/sandboxes/create-and-manage.json b/pr-preview/pr-291/sandboxes/create-and-manage.json index c9b01b1e4..03ab44d73 100644 --- a/pr-preview/pr-291/sandboxes/create-and-manage.json +++ b/pr-preview/pr-291/sandboxes/create-and-manage.json @@ -1 +1 @@ -{"id":"sandboxes/create-and-manage","title":"Create and Manage Sandboxes","url":"sandboxes/create-and-manage.html","last_modified":"2026-03-14T00:12:41.752318+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create, inspect, connect to, monitor, transfer files, and delete OpenShell sandboxes.","tags":["Sandboxing","AI Agents","Sandbox Management","CLI"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Create and Manage Sandboxes This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes . Docker must be running before you create a sandbox. If it is not, the CLI\nreturns a connection-refused error ( os error 61 ) without explaining\nthe cause. Start Docker and try again. Create a Sandbox Run a single command to create a sandbox and launch your agent: $ openshell sandbox create -- claude\nIf you have an existing gateway, the sandbox is created in it. Otherwise, a gateway is created automatically. To request GPU resources explicitly, add --gpu : $ openshell sandbox create --gpu -- claude\nIf no gateway is running, the auto-bootstrap path starts a GPU-enabled gateway first. A fully specified creation command might look like: $ openshell sandbox create\nname dev\nprovider my-claude\npolicy policy.yaml\nupload\nclaude\nSandboxes created with openshell sandbox create stay running by default after\nthe initial command or shell exits. Use --no-keep when you want the sandbox\ndeleted automatically instead. Create from a Community Sandbox or Custom Image Use --from to create a sandbox from a pre-built community package, a local directory, or a container image: $ openshell sandbox create --from openclaw\nThe CLI resolves the name against the OpenShell Community catalog, pulls the bundled Dockerfile and policy, builds the image locally, and creates the sandbox. For the full catalog and how to contribute your own, refer to community-sandboxes . You can also point --from at a local directory or a container image reference: $ openshell sandbox create --from ./my-sandbox-dir\nopenshell sandbox create --from my-registry.example.com/my-image:latest\nImages whose final name component contains gpu also trigger GPU sandbox requests automatically. For example, --from nvidia-gpu behaves like a GPU sandbox request even without --gpu . List and Inspect Sandboxes Check the status of your sandboxes and retrieve detailed information about individual ones. List all sandboxes: $ openshell sandbox list\nGet detailed information about a specific sandbox: $ openshell sandbox get my-sandbox\nConnect to a Sandbox Access a running sandbox through an interactive SSH session or VS Code Remote-SSH. Interactive SSH Open an SSH session into a running sandbox: $ openshell sandbox connect my-sandbox\nOpen in a remote editor Launch VS Code or Cursor directly into the sandbox workspace: $ openshell sandbox create --editor vscode --name my-sandbox\nopenshell sandbox connect my-sandbox --editor cursor\nWhen --editor is used, OpenShell keeps the sandbox alive and installs an\nOpenShell-managed SSH include file instead of cluttering your main\nssh/config with generated host blocks. View Logs Stream and filter sandbox logs to monitor agent activity and diagnose policy decisions. Stream sandbox logs: $ openshell logs my-sandbox\nUse flags to filter and follow output: Flag Purpose Example --tail Stream logs in real time openshell logs my-sandbox --tail --source Filter by log source --source sandbox --level Filter by severity --level warn --since Show logs from a time window --since 5m Monitor Your Sandbox OpenShell Terminal is a real-time dashboard that combines sandbox status and live logs in a single view. $ openshell term\nThe dashboard shows the following information. Sandbox status : Name, phase, image, attached providers, age, and active port forwards. Live log stream : Omutbound connections, policy decisions, and inference interceptions as they happen. Logs are labeled by source: sandbox (proxy and policy events) or gateway (lifecycle events). Use the terminal to spot blocked connections ( action=deny entries) and inference interceptions ( action=inspect_for_inference entries). If a connection is blocked unexpectedly, add the host to your network policy — refer to policies for the workflow. Transfer Files Transfer files between your host machine and a running sandbox. Upload files from your host into the sandbox: $ openshell sandbox upload my-sandbox ./src /sandbox/src\nDownload files from the sandbox to your host: $ openshell sandbox download my-sandbox /sandbox/output ./local\nYou can also upload files at creation time with the --upload flag on\nopenshell sandbox create . Delete Sandboxes Remove sandboxes when they are no longer needed. Deleting a sandbox stops all processes, releases cluster resources, and purges injected credentials. Delete a sandbox by name: $ openshell sandbox delete my-sandbox\nDelete all sandboxes in the active gateway: $ openshell sandbox delete --all\nNext Steps Explore related topics: To follow a complete end-to-end example, refer to the /tutorials/github-sandbox tutorial. To supply API keys or tokens, refer to providers . To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog","format":"text","summary":"This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes.","headings":[{"text":"Create and Manage Sandboxes","level":1},{"text":"Create a Sandbox","level":2},{"text":"Create from a Community Sandbox or Custom Image","level":2},{"text":"List and Inspect Sandboxes","level":2},{"text":"Connect to a Sandbox","level":2},{"text":"Interactive SSH","level":3},{"text":"Open in a remote editor","level":3},{"text":"View Logs","level":2},{"text":"Monitor Your Sandbox","level":2},{"text":"Transfer Files","level":2},{"text":"Delete Sandboxes","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file +{"id":"sandboxes/create-and-manage","title":"Create and Manage Sandboxes","url":"sandboxes/create-and-manage.html","last_modified":"2026-03-14T00:20:51.666062+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create, inspect, connect to, monitor, transfer files, and delete OpenShell sandboxes.","tags":["Sandboxing","AI Agents","Sandbox Management","CLI"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Create and Manage Sandboxes This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes . Docker must be running before you create a sandbox. If it is not, the CLI\nreturns a connection-refused error ( os error 61 ) without explaining\nthe cause. Start Docker and try again. Create a Sandbox Run a single command to create a sandbox and launch your agent: $ openshell sandbox create -- claude\nIf you have an existing gateway, the sandbox is created in it. Otherwise, a gateway is created automatically. To request GPU resources explicitly, add --gpu : $ openshell sandbox create --gpu -- claude\nIf no gateway is running, the auto-bootstrap path starts a GPU-enabled gateway first. A fully specified creation command might look like: $ openshell sandbox create\nname dev\nprovider my-claude\npolicy policy.yaml\nupload\nclaude\nSandboxes created with openshell sandbox create stay running by default after\nthe initial command or shell exits. Use --no-keep when you want the sandbox\ndeleted automatically instead. Create from a Community Sandbox or Custom Image Use --from to create a sandbox from a pre-built community package, a local directory, or a container image: $ openshell sandbox create --from openclaw\nThe CLI resolves the name against the OpenShell Community catalog, pulls the bundled Dockerfile and policy, builds the image locally, and creates the sandbox. For the full catalog and how to contribute your own, refer to community-sandboxes . You can also point --from at a local directory or a container image reference: $ openshell sandbox create --from ./my-sandbox-dir\nopenshell sandbox create --from my-registry.example.com/my-image:latest\nImages whose final name component contains gpu also trigger GPU sandbox requests automatically. For example, --from nvidia-gpu behaves like a GPU sandbox request even without --gpu . List and Inspect Sandboxes Check the status of your sandboxes and retrieve detailed information about individual ones. List all sandboxes: $ openshell sandbox list\nGet detailed information about a specific sandbox: $ openshell sandbox get my-sandbox\nConnect to a Sandbox Access a running sandbox through an interactive SSH session or VS Code Remote-SSH. Interactive SSH Open an SSH session into a running sandbox: $ openshell sandbox connect my-sandbox\nOpen in a remote editor Launch VS Code or Cursor directly into the sandbox workspace: $ openshell sandbox create --editor vscode --name my-sandbox\nopenshell sandbox connect my-sandbox --editor cursor\nWhen --editor is used, OpenShell keeps the sandbox alive and installs an\nOpenShell-managed SSH include file instead of cluttering your main\nssh/config with generated host blocks. View Logs Stream and filter sandbox logs to monitor agent activity and diagnose policy decisions. Stream sandbox logs: $ openshell logs my-sandbox\nUse flags to filter and follow output: Flag Purpose Example --tail Stream logs in real time openshell logs my-sandbox --tail --source Filter by log source --source sandbox --level Filter by severity --level warn --since Show logs from a time window --since 5m Monitor Your Sandbox OpenShell Terminal is a real-time dashboard that combines sandbox status and live logs in a single view. $ openshell term\nThe dashboard shows the following information. Sandbox status : Name, phase, image, attached providers, age, and active port forwards. Live log stream : Omutbound connections, policy decisions, and inference interceptions as they happen. Logs are labeled by source: sandbox (proxy and policy events) or gateway (lifecycle events). Use the terminal to spot blocked connections ( action=deny entries) and inference interceptions ( action=inspect_for_inference entries). If a connection is blocked unexpectedly, add the host to your network policy — refer to policies for the workflow. Transfer Files Transfer files between your host machine and a running sandbox. Upload files from your host into the sandbox: $ openshell sandbox upload my-sandbox ./src /sandbox/src\nDownload files from the sandbox to your host: $ openshell sandbox download my-sandbox /sandbox/output ./local\nYou can also upload files at creation time with the --upload flag on\nopenshell sandbox create . Delete Sandboxes Remove sandboxes when they are no longer needed. Deleting a sandbox stops all processes, releases cluster resources, and purges injected credentials. Delete a sandbox by name: $ openshell sandbox delete my-sandbox\nDelete all sandboxes in the active gateway: $ openshell sandbox delete --all\nNext Steps Explore related topics: To follow a complete end-to-end example, refer to the /tutorials/github-sandbox tutorial. To supply API keys or tokens, refer to providers . To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog","format":"text","summary":"This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes.","headings":[{"text":"Create and Manage Sandboxes","level":1},{"text":"Create a Sandbox","level":2},{"text":"Create from a Community Sandbox or Custom Image","level":2},{"text":"List and Inspect Sandboxes","level":2},{"text":"Connect to a Sandbox","level":2},{"text":"Interactive SSH","level":3},{"text":"Open in a remote editor","level":3},{"text":"View Logs","level":2},{"text":"Monitor Your Sandbox","level":2},{"text":"Transfer Files","level":2},{"text":"Delete Sandboxes","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/sandboxes/index.json b/pr-preview/pr-291/sandboxes/index.json index ea093b58b..87aa336ed 100644 --- a/pr-preview/pr-291/sandboxes/index.json +++ b/pr-preview/pr-291/sandboxes/index.json @@ -1 +1 @@ -{"id":"sandboxes/index","title":"About Sandboxes","url":"sandboxes/index.html","last_modified":"2026-03-14T00:12:41.757407+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Understand sandbox lifecycle, supported agents, built-in default policy, and network access rules in OpenShell.","tags":["Sandboxing","AI Agents","Security","Policy","Isolation"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"About Sandboxes An OpenShell sandbox is a safe, private execution environment for an AI agent. Each sandbox runs with multiple layers of protection that prevent unauthorized data access, credential exposure, and network exfiltration. Protection layers include filesystem restrictions (Landlock), system call filtering (seccomp), network namespace isolation, and a privacy-enforcing HTTP CONNECT proxy. Sandbox Lifecycle Every sandbox moves through a defined set of phases: Phase Description Provisioning The runtime is setting up the sandbox environment, injecting credentials, and applying your policy. Ready The sandbox is running. The agent process is active and all isolation layers are enforced. You can connect, sync files, and view logs. Error Something went wrong during provisioning or execution. Check logs with openshell logs for details. Deleting The sandbox is being torn down. The system releases resources and purges credentials. Supported Agents The following table summarizes the agents that run in OpenShell sandboxes. All agent sandbox images are maintained in the OpenShell Community repository. Agents in the base image are auto-configured when passed as the trailing command to openshell sandbox create . More community agent sandboxes are available in the community-sandboxes catalog. Agent Source Default Policy Notes Claude Code base Full coverage Works out of the box. Requires ANTHROPIC_API_KEY . OpenCode base Partial coverage Pre-installed. Add opencode.ai endpoint and OpenCode binary paths to the policy for full functionality. Codex base No coverage Pre-installed. Requires a custom policy with OpenAI endpoints and Codex binary paths. Requires OPENAI_API_KEY . OpenClaw openclaw Bundled Agent orchestration layer. Launch with openshell sandbox create --from openclaw\nBuilt-in Default Policy OpenShell ships a built-in policy that covers common agent workflows out of the box\nWhen you create a sandbox without --policy , the default policy is applied. It controls three things: Layer What It Controls How It Works Filesystem What the agent can access on disk Paths are split into read-only and read-write sets. Landlock LSM enforces these restrictions at the kernel level. Network What the agent can reach on the network Each policy block pairs allowed destinations (host and port) with allowed binaries (executable paths). The proxy matches every outbound connection to the binary that opened it. Both must match or the connection is denied. Process What privileges the agent has The agent runs as an unprivileged user with seccomp filters that block dangerous system calls. No sudo , no setuid , no path to elevated privileges. For the full breakdown of each default policy block and agent compatibility details, refer to ../reference/default-policy . Policy Structure A policy has static sections ( filesystem_policy , landlock , process ) that are locked at sandbox creation, and dynamic sections ( network_policies , inference ) that are hot-reloadable on a running sandbox. version: 1\nStatic: locked at sandbox creation. Paths the agent can read vs read/write\nfilesystem_policy\nread_only: [/usr, /lib, /etc\nread_write: [/sandbox, /tmp\nStatic: Landlock LSM kernel enforcement. best_effort uses highest ABI the host supports\nlandlock\ncompatibility: best_effort\nStatic: Unprivileged user/group the agent process runs as\nprocess\nrun_as_user: sandbox\nrun_as_group: sandbox\nDynamic: hot-reloadable. Named blocks of endpoints + binaries allowed to reach them\nnetwork_policies\nmy_api\nname: my-api\nendpoints\nhost: api.example.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\naccess: full\nbinaries\npath: /usr/bin/curl\nDynamic: hot-reloadable. Routing hints this sandbox can use for inference (e.g. local, nvidia\ninference\nallowed_routes: [local\nFor the complete structure and every field, refer to the Policy Schema Reference . Network Access Rules Network access is controlled by policy blocks under network_policies . Each block has a name, a list of endpoints (host, port, protocol, and optional rules), and a list of binaries that are allowed to use those endpoints. Every outbound connection from the sandbox goes through the proxy: The proxy queries the policy engine with the destination (host and port) and the calling binary. A connection is allowed only when both match an entry in the same policy block. For endpoints with protocol: rest and tls: terminate , each HTTP request is checked against that endpoint’s rules (method and path). If no endpoint matches and inference routes are configured, the request may be rerouted for inference. Otherwise the connection is denied. Endpoints without protocol or tls allow the TCP stream through without inspecting payloads. Next Steps Continue with one of the following: To create your first sandbox, refer to create-and-manage . To supply API keys or tokens, refer to providers . To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog","format":"text","summary":"An OpenShell sandbox is a safe, private execution environment for an AI agent. Each sandbox runs with multiple layers of protection that prevent unauthorized data access, credential exposure, and network exfiltration. Protection layers include filesystem restrictions (Landlock), system call filte...","headings":[{"text":"About Sandboxes","level":1},{"text":"Sandbox Lifecycle","level":2},{"text":"Supported Agents","level":2},{"text":"Built-in Default Policy","level":2},{"text":"Policy Structure","level":2},{"text":"Network Access Rules","level":2},{"text":"Next Steps","level":2}],"children":[{"id":"sandboxes/community-sandboxes","title":"Community Sandboxes","url":"sandboxes/community-sandboxes.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Use pre-built sandboxes from the OpenShell Community catalog or contribute your own.","tags":["Community","Sandbox","Container Image","Open Source"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Community Sandboxes Use pre-built sandboxes from the OpenShell Community catalog, or contribute your\nown. What Are Community Sandboxes Community sandboxes are ready-to-use environments published in the\nOpenShell Community repository\nEach sandbox bundles a Dockerfile, policy, optional skills, and startup scripts\ninto a single package that you can launch with one command. Current Catalog The following community sandboxes are available in the catalog. Sandbox Description base Foundational image with system tools and dev environment openclaw Open agent manipulation and control sdg Synthetic data generation workflows simulation General-purpose simulation sandboxes Use a Community Sandbox Launch a community sandbox by name with the --from flag: $ openshell sandbox create --from openclaw\nWhen you pass --from with a community sandbox name, the CLI: Resolves the name against the\nOpenShell Community repository. Pulls the Dockerfile, policy, skills, and any startup scripts. Builds the container image locally. Creates the sandbox with the bundled configuration applied. You end up with a running sandbox whose image, policy, and tooling are all\npreconfigured by the community package. Other Sources The --from flag also accepts: Local directory paths: Point to a directory on disk that contains a\nDockerfile and optional policy/skills: $ openshell sandbox create --from ./my-sandbox-dir\nContainer image references: Use an existing container image directly: $ openshell sandbox create --from my-registry.example.com/my-image:latest\nContribute a Community Sandbox Each community sandbox is a directory under sandboxes/ in the\nOpenShell Community repository\nAt minimum, a sandbox directory must contain the following files: Dockerfile that defines the container image. README.md that describes the sandbox and how to use it. You can also include the following optional files: policy.yaml that defines the default policy applied when the sandbox launches. skills/ that contains agent skill definitions bundled with the sandbox. Startup scripts that are any scripts the Dockerfile or entrypoint invokes. To contribute, fork the repository, add your sandbox directory, and open a pull\nrequest. Refer to the repository’s\nCONTRIBUTING.md\nfor submission guidelines. The community catalog is designed to grow. If you have built a sandbox that\nsupports a particular workflow (data processing, simulation, code review\nor anything else), consider contributing it back so others can use it. Next Steps Explore related topics: Need to supply API keys or tokens? Set up providers for credential management. Want to customize the sandbox policy? Write custom rules in policies","format":"text","content_length":2663,"word_count":381,"summary":"Use pre-built sandboxes from the OpenShell Community catalog, or contribute your own.","headings":[{"text":"Community Sandboxes","level":1,"id":"community-sandboxes"},{"text":"What Are Community Sandboxes","level":2,"id":"what-are-community-sandboxes"},{"text":"Current Catalog","level":2,"id":"current-catalog"},{"text":"Use a Community Sandbox","level":2,"id":"use-a-community-sandbox"},{"text":"Other Sources","level":3,"id":"other-sources"},{"text":"Contribute a Community Sandbox","level":2,"id":"contribute-a-community-sandbox"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Community Sandboxes What Are Community Sandboxes Current Catalog Use a Community Sandbox Other Sources Contribute a Community Sandbox Next Steps","keywords":["accepts","builds","catalog","com","community","container","contribute","creates","current","description","directly","dockerfile","each","explore","files","flag","foundational","general","image","launch","local","need","next","open","openshell","other","paths","point","pulls","refer","references","resolves","sandbox","sandboxes","set","skills","sources","startup","steps","synthetic","topics","want","write","yaml"],"code_blocks":[{"content":"$ openshell sandbox create --from openclaw","language":"text"},{"content":"$ openshell sandbox create --from ./my-sandbox-dir","language":"text"},{"content":"$ openshell sandbox create --from my-registry.example.com/my-image:latest","language":"text"}],"links":[{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"},{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"},{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"},{"text":"Contributing","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community/blob/main/CONTRIBUTING.md","original_text":"CONTRIBUTING.md"}],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Community Sandboxes"]},{"id":"sandboxes/create-and-manage","title":"Create and Manage Sandboxes","url":"sandboxes/create-and-manage.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create, inspect, connect to, monitor, transfer files, and delete OpenShell sandboxes.","tags":["Sandboxing","AI Agents","Sandbox Management","CLI"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Create and Manage Sandboxes This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes . Docker must be running before you create a sandbox. If it is not, the CLI\nreturns a connection-refused error ( os error 61 ) without explaining\nthe cause. Start Docker and try again. Create a Sandbox Run a single command to create a sandbox and launch your agent: $ openshell sandbox create -- claude\nIf you have an existing gateway, the sandbox is created in it. Otherwise, a gateway is created automatically. To request GPU resources explicitly, add --gpu : $ openshell sandbox create --gpu -- claude\nIf no gateway is running, the auto-bootstrap path starts a GPU-enabled gateway first. A fully specified creation command might look like: $ openshell sandbox create\nname dev\nprovider my-claude\npolicy policy.yaml\nupload\nclaude\nSandboxes created with openshell sandbox create stay running by default after\nthe initial command or shell exits. Use --no-keep when you want the sandbox\ndeleted automatically instead. Create from a Community Sandbox or Custom Image Use --from to create a sandbox from a pre-built community package, a local directory, or a container image: $ openshell sandbox create --from openclaw\nThe CLI resolves the name against the OpenShell Community catalog, pulls the bundled Dockerfile and policy, builds the image locally, and creates the sandbox. For the full catalog and how to contribute your own, refer to community-sandboxes . You can also point --from at a local directory or a container image reference: $ openshell sandbox create --from ./my-sandbox-dir\nopenshell sandbox create --from my-registry.example.com/my-image:latest\nImages whose final name component contains gpu also trigger GPU sandbox requests automatically. For example, --from nvidia-gpu behaves like a GPU sandbox request even without --gpu . List and Inspect Sandboxes Check the status of your sandboxes and retrieve detailed information about individual ones. List all sandboxes: $ openshell sandbox list\nGet detailed information about a specific sandbox: $ openshell sandbox get my-sandbox\nConnect to a Sandbox Access a running sandbox through an interactive SSH session or VS Code Remote-SSH. Interactive SSH Open an SSH session into a running sandbox: $ openshell sandbox connect my-sandbox\nOpen in a remote editor Launch VS Code or Cursor directly into the sandbox workspace: $ openshell sandbox create --editor vscode --name my-sandbox\nopenshell sandbox connect my-sandbox --editor cursor\nWhen --editor is used, OpenShell keeps the sandbox alive and installs an\nOpenShell-managed SSH include file instead of cluttering your main\nssh/config with generated host blocks. View Logs Stream and filter sandbox logs to monitor agent activity and diagnose policy decisions. Stream sandbox logs: $ openshell logs my-sandbox\nUse flags to filter and follow output: Flag Purpose Example --tail Stream logs in real time openshell logs my-sandbox --tail --source Filter by log source --source sandbox --level Filter by severity --level warn --since Show logs from a time window --since 5m Monitor Your Sandbox OpenShell Terminal is a real-time dashboard that combines sandbox status and live logs in a single view. $ openshell term\nThe dashboard shows the following information. Sandbox status : Name, phase, image, attached providers, age, and active port forwards. Live log stream : Omutbound connections, policy decisions, and inference interceptions as they happen. Logs are labeled by source: sandbox (proxy and policy events) or gateway (lifecycle events). Use the terminal to spot blocked connections ( action=deny entries) and inference interceptions ( action=inspect_for_inference entries). If a connection is blocked unexpectedly, add the host to your network policy — refer to policies for the workflow. Transfer Files Transfer files between your host machine and a running sandbox. Upload files from your host into the sandbox: $ openshell sandbox upload my-sandbox ./src /sandbox/src\nDownload files from the sandbox to your host: $ openshell sandbox download my-sandbox /sandbox/output ./local\nYou can also upload files at creation time with the --upload flag on\nopenshell sandbox create . Delete Sandboxes Remove sandboxes when they are no longer needed. Deleting a sandbox stops all processes, releases cluster resources, and purges injected credentials. Delete a sandbox by name: $ openshell sandbox delete my-sandbox\nDelete all sandboxes in the active gateway: $ openshell sandbox delete --all\nNext Steps Explore related topics: To follow a complete end-to-end example, refer to the /tutorials/github-sandbox tutorial. To supply API keys or tokens, refer to providers . To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog","format":"text","content_length":4956,"word_count":750,"summary":"This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes.","headings":[{"text":"Create and Manage Sandboxes","level":1,"id":"create-and-manage-sandboxes"},{"text":"Create a Sandbox","level":2,"id":"create-a-sandbox"},{"text":"Create from a Community Sandbox or Custom Image","level":2,"id":"create-from-a-community-sandbox-or-custom-image"},{"text":"List and Inspect Sandboxes","level":2,"id":"list-and-inspect-sandboxes"},{"text":"Connect to a Sandbox","level":2,"id":"connect-to-a-sandbox"},{"text":"Interactive SSH","level":3,"id":"interactive-ssh"},{"text":"Open in a remote editor","level":3,"id":"open-in-a-remote-editor"},{"text":"View Logs","level":2,"id":"view-logs"},{"text":"Monitor Your Sandbox","level":2,"id":"monitor-your-sandbox"},{"text":"Transfer Files","level":2,"id":"transfer-files"},{"text":"Delete Sandboxes","level":2,"id":"delete-sandboxes"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Create and Manage Sandboxes Create a Sandbox Create from a Community Sandbox or Custom Image List and Inspect Sandboxes Connect to a Sandbox Interactive SSH Open in a remote editor View Logs Monitor Your Sandbox Transfer Files Delete Sandboxes Next Steps","keywords":["about","access","action","agent","check","code","com","community","connect","create","cursor","custom","delete","deleting","docker","dockerfile","download","editor","example","explore","files","filter","flag","from","gateway","gpu","host","image","images","inspect","interactive","launch","lifecycle","like","list","live","logs","manage","monitor","name","next","omutbound","open","openshell","otherwise","output","purpose","reference","remote","remove"],"code_blocks":[{"content":"$ openshell sandbox create -- claude","language":"text"},{"content":"$ openshell sandbox create --gpu -- claude","language":"text"},{"content":"$ openshell sandbox create \\\n --name dev \\\n --provider my-claude \\\n --policy policy.yaml \\\n --upload \\\n -- claude","language":"text"},{"content":"$ openshell sandbox create --from openclaw","language":"text"},{"content":"$ openshell sandbox create --from ./my-sandbox-dir\n$ openshell sandbox create --from my-registry.example.com/my-image:latest","language":"text"},{"content":"$ openshell sandbox list","language":"text"},{"content":"$ openshell sandbox get my-sandbox","language":"text"},{"content":"$ openshell sandbox connect my-sandbox","language":"text"},{"content":"$ openshell sandbox create --editor vscode --name my-sandbox\n$ openshell sandbox connect my-sandbox --editor cursor","language":"text"},{"content":"$ openshell logs my-sandbox","language":"text"},{"content":"$ openshell term","language":"text"},{"content":"$ openshell sandbox upload my-sandbox ./src /sandbox/src","language":"text"},{"content":"$ openshell sandbox download my-sandbox /sandbox/output ./local","language":"text"},{"content":"$ openshell sandbox delete my-sandbox","language":"text"},{"content":"$ openshell sandbox delete --all","language":"text"}],"links":[{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"}],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Create And Manage"]},{"id":"sandboxes/policies","title":"Customize Sandbox Policies","url":"sandboxes/policies.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Apply, iterate, and debug sandbox network policies with hot-reload on running OpenShell sandboxes.","tags":["Policy","Network Policy","Sandbox","Security","Hot Reload"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Customize Sandbox Policies Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference . Quick Start: Apply a Custom Policy Pass a policy YAML file when creating the sandbox: $ openshell sandbox create --policy ./my-policy.yaml -- claude\nopenshell sandbox create keeps the sandbox running after the initial command exits, which is useful when you plan to iterate on the policy. Add --no-keep if you want the sandbox deleted automatically instead. To avoid passing --policy every time, set a default policy with an environment variable: $ export OPENSHELL_SANDBOX_POLICY=./my-policy.yaml\nopenshell sandbox create -- claude\nThe CLI uses the policy from OPENSHELL_SANDBOX_POLICY whenever --policy is not explicitly provided. Iterate on a Running Sandbox To change what the sandbox can access, pull the current policy, edit the YAML, and push the update. The workflow is iterative: create the sandbox, monitor logs for denied actions, pull the policy, modify it, push, and verify. The following steps outline the hot-reload policy update workflow. Create the sandbox with your initial policy by following Quick Start: Apply a Custom Policy above (or set OPENSHELL_SANDBOX_POLICY ). Monitor denials. Each log entry shows host, port, binary, and reason. Alternatively, use openshell term for a live dashboard. $ openshell logs --tail --source sandbox\nPull the current policy. Strip the metadata header (Version, Hash, Status) before reusing the file. $ openshell policy get --full > current-policy.yaml\nEdit the YAML: add or adjust network_policies entries, binaries, access or rules , or inference.allowed_routes . Push the updated policy. Exit codes: 0 = loaded, 1 = validation failed, 124 = timeout. $ openshell policy set --policy current-policy.yaml --wait\nVerify the new revision. If status is loaded , repeat from step 2 as needed; if failed , fix the policy and repeat from step 4. $ openshell policy list --tail --source sandbox for the denied host, path, and binary. When triaging denied requests, check: Destination host and port to confirm which endpoint is missing. Calling binary path to confirm which binaries entry needs to be added or adjusted. HTTP method and path (for REST endpoints) to confirm which rules entry needs to be added or adjusted. Then push the updated policy as described above. Examples Add these blocks to the network_policies section of your sandbox policy. Apply with openshell policy set --policy --wait\nUse Simple endpoint for host-level allowlists and Granular rules for method/path control. Simple endpoint Allow pip install and uv pip install to reach PyPI: pypi\nname: pypi\nendpoints\nhost: pypi.org\nport: 443\nhost: files.pythonhosted.org\nport: 443\nbinaries\n{ path: /usr/bin/pip\n{ path: /usr/local/bin/uv\nEndpoints without protocol or tls use TCP passthrough — the proxy allows the stream without inspecting payloads. Granular rules Allow Claude and the GitHub CLI to reach api.github.com with per-path rules: read-only (GET, HEAD, OPTIONS) and GraphQL (POST) for all paths; full write access for alpha-repo ; and create/edit issues only for bravo-repo . Replace with your GitHub org or username. For an end-to-end walkthrough that combines this policy with a GitHub credential provider and sandbox creation, refer to /tutorials/github-sandbox . github_repos\nname: github_repos\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nallow\nmethod: GET\npath:\nallow\nmethod: HEAD\npath:\nallow\nmethod: OPTIONS\npath:\nallow\nmethod: POST\npath: \"/graphql\nallow\nmethod:\npath: \"/repos//alpha-repo\nallow\nmethod: POST\npath: \"/repos//bravo-repo/issues\nallow\nmethod: PATCH\npath: \"/repos//bravo-repo/issues\nbinaries\n{ path: /usr/local/bin/claude\n{ path: /usr/bin/gh\nEndpoints with protocol: rest and tls: terminate enable HTTP request inspection — the proxy decrypts TLS and checks each HTTP request against the rules list. Next Steps Explore related topics: To learn about policy structure and network access rules, refer to index . To view the full field-by-field YAML definition, refer to the Policy Schema Reference . To review the default policy breakdown, refer to ../reference/default-policy","format":"text","content_length":4379,"word_count":647,"summary":"Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference.","headings":[{"text":"Customize Sandbox Policies","level":1,"id":"customize-sandbox-policies"},{"text":"Quick Start: Apply a Custom Policy","level":2,"id":"quick-start-apply-a-custom-policy"},{"text":"Iterate on a Running Sandbox","level":2,"id":"iterate-on-a-running-sandbox"},{"text":"Debug Denied Requests","level":2,"id":"debug-denied-requests"},{"text":"Examples","level":2,"id":"examples"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Customize Sandbox Policies Quick Start: Apply a Custom Policy Iterate on a Running Sandbox Debug Denied Requests Examples Next Steps","keywords":["add","allow","alternatively","apply","calling","check","claude","codes","com","create","custom","customize","debug","denied","destination","each","edit","endpoints","enforcement","examples","exit","explore","github","granular","graphql","hash","host","iterate","iterative","method","monitor","name","next","org","pass","path","policies","policy","port","protocol","pull","push","pypi","quick","reference","replace","requests","rules","running","sandbox"],"code_blocks":[{"content":"$ openshell sandbox create --policy ./my-policy.yaml -- claude","language":"text"},{"content":"$ export OPENSHELL_SANDBOX_POLICY=./my-policy.yaml\n$ openshell sandbox create -- claude","language":"text"},{"content":"$ openshell logs --tail --source sandbox","language":"text"},{"content":"$ openshell policy get --full > current-policy.yaml","language":"text"},{"content":"$ openshell policy set --policy current-policy.yaml --wait","language":"text"},{"content":"$ openshell policy list ","language":"text"},{"content":"pypi:\n name: pypi\n endpoints:\n - host: pypi.org\n port: 443\n - host: files.pythonhosted.org\n port: 443\n binaries:\n - { path: /usr/bin/pip }\n - { path: /usr/local/bin/uv }","language":"text"},{"content":"github_repos:\n name: github_repos\n endpoints:\n - host: api.github.com\n port: 443\n protocol: rest\n tls: terminate\n enforcement: enforce\n rules:\n - allow:\n method: GET\n path: \"/**\"\n - allow:\n method: HEAD\n path: \"/**\"\n - allow:\n method: OPTIONS\n path: \"/**\"\n - allow:\n method: POST\n path: \"/graphql\"\n - allow:\n method: \"*\"\n path: \"/repos//alpha-repo/**\"\n - allow:\n method: POST\n path: \"/repos//bravo-repo/issues\"\n - allow:\n method: PATCH\n path: \"/repos//bravo-repo/issues/*\"\n binaries:\n - { path: /usr/local/bin/claude }\n - { path: /usr/bin/gh }","language":"text"}],"links":[{"text":"Quick Start: Apply a Custom Policy","type":"anchor","url":"#quick-start-apply-a-custom-policy"}],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Policies"]},{"id":"sandboxes/providers","title":"Providers","url":"sandboxes/providers.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create and manage credential providers that inject API keys and tokens into OpenShell sandboxes.","tags":["Providers","Credentials","API Keys","Sandbox","Security"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Providers AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers . Create and manage providers that supply credentials to sandboxes. Create a Provider Providers can be created from local environment variables or with explicit credential values. From Local Credentials The fastest way to create a provider is to let the CLI discover credentials from\nyour shell environment: $ openshell provider create --name my-claude --type claude --from-existing\nThis reads ANTHROPIC_API_KEY or CLAUDE_API_KEY from your current environment\nand stores them in the provider. With Explicit Credentials Supply a credential value directly: $ openshell provider create --name my-api --type generic --credential API_KEY=sk-abc123\nBare Key Form Pass a key name without a value to read the value from the environment variable\nof that name: $ openshell provider create --name my-api --type generic --credential API_KEY\nThis looks up the current value of $API_KEY in your shell and stores it. Manage Providers List, inspect, update, and delete providers from the active cluster. List all providers: $ openshell provider list\nInspect a provider: $ openshell provider get my-claude\nUpdate a provider’s credentials: $ openshell provider update my-claude --type claude --from-existing\nDelete a provider: $ openshell provider delete my-claude\nAttach Providers to Sandboxes Pass one or more --provider flags when creating a sandbox: $ openshell sandbox create --provider my-claude --provider my-github -- claude\nEach --provider flag attaches one provider. The sandbox receives all\ncredentials from every attached provider at runtime. Providers cannot be added to a running sandbox. If you need to attach an\nadditional provider, delete the sandbox and recreate it with all required\nproviders specified. Auto-Discovery Shortcut When the trailing command in openshell sandbox create is a recognized tool name ( claude , codex , or opencode ), the CLI auto-creates the required\nprovider from your local credentials if one does not already exist. You do not\nneed to create the provider separately: $ openshell sandbox create -- claude\nThis detects claude as a known tool, finds your ANTHROPIC_API_KEY , creates\na provider, attaches it to the sandbox, and launches Claude Code. Supported Provider Types The following provider types are supported. Type Environment Variables Injected Typical Use claude ANTHROPIC_API_KEY , CLAUDE_API_KEY Claude Code, Anthropic API codex OPENAI_API_KEY OpenAI Codex opencode OPENCODE_API_KEY , OPENROUTER_API_KEY , OPENAI_API_KEY opencode tool github GITHUB_TOKEN , GH_TOKEN GitHub API, gh CLI — refer to /tutorials/github-sandbox gitlab GITLAB_TOKEN , GLAB_TOKEN , CI_JOB_TOKEN GitLab API, glab CLI nvidia NVIDIA_API_KEY NVIDIA API Catalog generic User-defined Any service with custom credentials outlook (none: no auto-discovery) Microsoft Outlook integration Use the generic type for any service not listed above. You define the\nenvironment variable names and values yourself with --credential . Next Steps Explore related topics: To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog. To view the complete field reference for the policy YAML, refer to the Policy Schema Reference","format":"text","content_length":3421,"word_count":502,"summary":"AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers.","headings":[{"text":"Providers","level":1,"id":"providers"},{"text":"Create a Provider","level":2,"id":"create-a-provider"},{"text":"From Local Credentials","level":3,"id":"from-local-credentials"},{"text":"With Explicit Credentials","level":3,"id":"with-explicit-credentials"},{"text":"Bare Key Form","level":3,"id":"bare-key-form"},{"text":"Manage Providers","level":2,"id":"manage-providers"},{"text":"Attach Providers to Sandboxes","level":2,"id":"attach-providers-to-sandboxes"},{"text":"Auto-Discovery Shortcut","level":3,"id":"auto-discovery-shortcut"},{"text":"Supported Provider Types","level":2,"id":"supported-provider-types"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Providers Create a Provider From Local Credentials With Explicit Credentials Bare Key Form Manage Providers Attach Providers to Sandboxes Auto-Discovery Shortcut Supported Provider Types Next Steps","keywords":["anthropic","any","attach","auto","bare","catalog","claude","code","codex","create","credentials","delete","directly","discovery","each","environment","explicit","explore","form","from","github","gitlab","injected","inspect","key","list","local","manage","microsoft","name","next","none","openai","openshell","outlook","pass","policy","provider","providers","reference","sandbox","sandboxes","schema","separately","services","shortcut","steps","supply","supported","this"],"code_blocks":[{"content":"$ openshell provider create --name my-claude --type claude --from-existing","language":"text"},{"content":"$ openshell provider create --name my-api --type generic --credential API_KEY=sk-abc123","language":"text"},{"content":"$ openshell provider create --name my-api --type generic --credential API_KEY","language":"text"},{"content":"$ openshell provider list","language":"text"},{"content":"$ openshell provider get my-claude","language":"text"},{"content":"$ openshell provider update my-claude --type claude --from-existing","language":"text"},{"content":"$ openshell provider delete my-claude","language":"text"},{"content":"$ openshell sandbox create --provider my-claude --provider my-github -- claude","language":"text"},{"content":"$ openshell sandbox create -- claude","language":"text"}],"links":[],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Providers"]}]} \ No newline at end of file +{"id":"sandboxes/index","title":"About Sandboxes","url":"sandboxes/index.html","last_modified":"2026-03-14T00:20:51.672823+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Understand sandbox lifecycle, supported agents, built-in default policy, and network access rules in OpenShell.","tags":["Sandboxing","AI Agents","Security","Policy","Isolation"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"About Sandboxes An OpenShell sandbox is a safe, private execution environment for an AI agent. Each sandbox runs with multiple layers of protection that prevent unauthorized data access, credential exposure, and network exfiltration. Protection layers include filesystem restrictions (Landlock), system call filtering (seccomp), network namespace isolation, and a privacy-enforcing HTTP CONNECT proxy. Sandbox Lifecycle Every sandbox moves through a defined set of phases: Phase Description Provisioning The runtime is setting up the sandbox environment, injecting credentials, and applying your policy. Ready The sandbox is running. The agent process is active and all isolation layers are enforced. You can connect, sync files, and view logs. Error Something went wrong during provisioning or execution. Check logs with openshell logs for details. Deleting The sandbox is being torn down. The system releases resources and purges credentials. Supported Agents The following table summarizes the agents that run in OpenShell sandboxes. All agent sandbox images are maintained in the OpenShell Community repository. Agents in the base image are auto-configured when passed as the trailing command to openshell sandbox create . More community agent sandboxes are available in the community-sandboxes catalog. Agent Source Default Policy Notes Claude Code base Full coverage Works out of the box. Requires ANTHROPIC_API_KEY . OpenCode base Partial coverage Pre-installed. Add opencode.ai endpoint and OpenCode binary paths to the policy for full functionality. Codex base No coverage Pre-installed. Requires a custom policy with OpenAI endpoints and Codex binary paths. Requires OPENAI_API_KEY . OpenClaw openclaw Bundled Agent orchestration layer. Launch with openshell sandbox create --from openclaw\nBuilt-in Default Policy OpenShell ships a built-in policy that covers common agent workflows out of the box\nWhen you create a sandbox without --policy , the default policy is applied. It controls three things: Layer What It Controls How It Works Filesystem What the agent can access on disk Paths are split into read-only and read-write sets. Landlock LSM enforces these restrictions at the kernel level. Network What the agent can reach on the network Each policy block pairs allowed destinations (host and port) with allowed binaries (executable paths). The proxy matches every outbound connection to the binary that opened it. Both must match or the connection is denied. Process What privileges the agent has The agent runs as an unprivileged user with seccomp filters that block dangerous system calls. No sudo , no setuid , no path to elevated privileges. For the full breakdown of each default policy block and agent compatibility details, refer to ../reference/default-policy . Policy Structure A policy has static sections ( filesystem_policy , landlock , process ) that are locked at sandbox creation, and dynamic sections ( network_policies , inference ) that are hot-reloadable on a running sandbox. version: 1\nStatic: locked at sandbox creation. Paths the agent can read vs read/write\nfilesystem_policy\nread_only: [/usr, /lib, /etc\nread_write: [/sandbox, /tmp\nStatic: Landlock LSM kernel enforcement. best_effort uses highest ABI the host supports\nlandlock\ncompatibility: best_effort\nStatic: Unprivileged user/group the agent process runs as\nprocess\nrun_as_user: sandbox\nrun_as_group: sandbox\nDynamic: hot-reloadable. Named blocks of endpoints + binaries allowed to reach them\nnetwork_policies\nmy_api\nname: my-api\nendpoints\nhost: api.example.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\naccess: full\nbinaries\npath: /usr/bin/curl\nDynamic: hot-reloadable. Routing hints this sandbox can use for inference (e.g. local, nvidia\ninference\nallowed_routes: [local\nFor the complete structure and every field, refer to the Policy Schema Reference . Network Access Rules Network access is controlled by policy blocks under network_policies . Each block has a name, a list of endpoints (host, port, protocol, and optional rules), and a list of binaries that are allowed to use those endpoints. Every outbound connection from the sandbox goes through the proxy: The proxy queries the policy engine with the destination (host and port) and the calling binary. A connection is allowed only when both match an entry in the same policy block. For endpoints with protocol: rest and tls: terminate , each HTTP request is checked against that endpoint’s rules (method and path). If no endpoint matches and inference routes are configured, the request may be rerouted for inference. Otherwise the connection is denied. Endpoints without protocol or tls allow the TCP stream through without inspecting payloads. Next Steps Continue with one of the following: To create your first sandbox, refer to create-and-manage . To supply API keys or tokens, refer to providers . To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog","format":"text","summary":"An OpenShell sandbox is a safe, private execution environment for an AI agent. Each sandbox runs with multiple layers of protection that prevent unauthorized data access, credential exposure, and network exfiltration. Protection layers include filesystem restrictions (Landlock), system call filte...","headings":[{"text":"About Sandboxes","level":1},{"text":"Sandbox Lifecycle","level":2},{"text":"Supported Agents","level":2},{"text":"Built-in Default Policy","level":2},{"text":"Policy Structure","level":2},{"text":"Network Access Rules","level":2},{"text":"Next Steps","level":2}],"children":[{"id":"sandboxes/community-sandboxes","title":"Community Sandboxes","url":"sandboxes/community-sandboxes.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Use pre-built sandboxes from the OpenShell Community catalog or contribute your own.","tags":["Community","Sandbox","Container Image","Open Source"],"topics":["Generative AI","Cybersecurity"],"content_type":"concept","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Community Sandboxes Use pre-built sandboxes from the OpenShell Community catalog, or contribute your\nown. What Are Community Sandboxes Community sandboxes are ready-to-use environments published in the\nOpenShell Community repository\nEach sandbox bundles a Dockerfile, policy, optional skills, and startup scripts\ninto a single package that you can launch with one command. Current Catalog The following community sandboxes are available in the catalog. Sandbox Description base Foundational image with system tools and dev environment openclaw Open agent manipulation and control sdg Synthetic data generation workflows simulation General-purpose simulation sandboxes Use a Community Sandbox Launch a community sandbox by name with the --from flag: $ openshell sandbox create --from openclaw\nWhen you pass --from with a community sandbox name, the CLI: Resolves the name against the\nOpenShell Community repository. Pulls the Dockerfile, policy, skills, and any startup scripts. Builds the container image locally. Creates the sandbox with the bundled configuration applied. You end up with a running sandbox whose image, policy, and tooling are all\npreconfigured by the community package. Other Sources The --from flag also accepts: Local directory paths: Point to a directory on disk that contains a\nDockerfile and optional policy/skills: $ openshell sandbox create --from ./my-sandbox-dir\nContainer image references: Use an existing container image directly: $ openshell sandbox create --from my-registry.example.com/my-image:latest\nContribute a Community Sandbox Each community sandbox is a directory under sandboxes/ in the\nOpenShell Community repository\nAt minimum, a sandbox directory must contain the following files: Dockerfile that defines the container image. README.md that describes the sandbox and how to use it. You can also include the following optional files: policy.yaml that defines the default policy applied when the sandbox launches. skills/ that contains agent skill definitions bundled with the sandbox. Startup scripts that are any scripts the Dockerfile or entrypoint invokes. To contribute, fork the repository, add your sandbox directory, and open a pull\nrequest. Refer to the repository’s\nCONTRIBUTING.md\nfor submission guidelines. The community catalog is designed to grow. If you have built a sandbox that\nsupports a particular workflow (data processing, simulation, code review\nor anything else), consider contributing it back so others can use it. Next Steps Explore related topics: Need to supply API keys or tokens? Set up providers for credential management. Want to customize the sandbox policy? Write custom rules in policies","format":"text","content_length":2663,"word_count":381,"summary":"Use pre-built sandboxes from the OpenShell Community catalog, or contribute your own.","headings":[{"text":"Community Sandboxes","level":1,"id":"community-sandboxes"},{"text":"What Are Community Sandboxes","level":2,"id":"what-are-community-sandboxes"},{"text":"Current Catalog","level":2,"id":"current-catalog"},{"text":"Use a Community Sandbox","level":2,"id":"use-a-community-sandbox"},{"text":"Other Sources","level":3,"id":"other-sources"},{"text":"Contribute a Community Sandbox","level":2,"id":"contribute-a-community-sandbox"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Community Sandboxes What Are Community Sandboxes Current Catalog Use a Community Sandbox Other Sources Contribute a Community Sandbox Next Steps","keywords":["accepts","builds","catalog","com","community","container","contribute","creates","current","description","directly","dockerfile","each","explore","files","flag","foundational","general","image","launch","local","need","next","open","openshell","other","paths","point","pulls","refer","references","resolves","sandbox","sandboxes","set","skills","sources","startup","steps","synthetic","topics","want","write","yaml"],"code_blocks":[{"content":"$ openshell sandbox create --from openclaw","language":"text"},{"content":"$ openshell sandbox create --from ./my-sandbox-dir","language":"text"},{"content":"$ openshell sandbox create --from my-registry.example.com/my-image:latest","language":"text"}],"links":[{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"},{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"},{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"},{"text":"Contributing","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community/blob/main/CONTRIBUTING.md","original_text":"CONTRIBUTING.md"}],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Community Sandboxes"]},{"id":"sandboxes/create-and-manage","title":"Create and Manage Sandboxes","url":"sandboxes/create-and-manage.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create, inspect, connect to, monitor, transfer files, and delete OpenShell sandboxes.","tags":["Sandboxing","AI Agents","Sandbox Management","CLI"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Create and Manage Sandboxes This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes . Docker must be running before you create a sandbox. If it is not, the CLI\nreturns a connection-refused error ( os error 61 ) without explaining\nthe cause. Start Docker and try again. Create a Sandbox Run a single command to create a sandbox and launch your agent: $ openshell sandbox create -- claude\nIf you have an existing gateway, the sandbox is created in it. Otherwise, a gateway is created automatically. To request GPU resources explicitly, add --gpu : $ openshell sandbox create --gpu -- claude\nIf no gateway is running, the auto-bootstrap path starts a GPU-enabled gateway first. A fully specified creation command might look like: $ openshell sandbox create\nname dev\nprovider my-claude\npolicy policy.yaml\nupload\nclaude\nSandboxes created with openshell sandbox create stay running by default after\nthe initial command or shell exits. Use --no-keep when you want the sandbox\ndeleted automatically instead. Create from a Community Sandbox or Custom Image Use --from to create a sandbox from a pre-built community package, a local directory, or a container image: $ openshell sandbox create --from openclaw\nThe CLI resolves the name against the OpenShell Community catalog, pulls the bundled Dockerfile and policy, builds the image locally, and creates the sandbox. For the full catalog and how to contribute your own, refer to community-sandboxes . You can also point --from at a local directory or a container image reference: $ openshell sandbox create --from ./my-sandbox-dir\nopenshell sandbox create --from my-registry.example.com/my-image:latest\nImages whose final name component contains gpu also trigger GPU sandbox requests automatically. For example, --from nvidia-gpu behaves like a GPU sandbox request even without --gpu . List and Inspect Sandboxes Check the status of your sandboxes and retrieve detailed information about individual ones. List all sandboxes: $ openshell sandbox list\nGet detailed information about a specific sandbox: $ openshell sandbox get my-sandbox\nConnect to a Sandbox Access a running sandbox through an interactive SSH session or VS Code Remote-SSH. Interactive SSH Open an SSH session into a running sandbox: $ openshell sandbox connect my-sandbox\nOpen in a remote editor Launch VS Code or Cursor directly into the sandbox workspace: $ openshell sandbox create --editor vscode --name my-sandbox\nopenshell sandbox connect my-sandbox --editor cursor\nWhen --editor is used, OpenShell keeps the sandbox alive and installs an\nOpenShell-managed SSH include file instead of cluttering your main\nssh/config with generated host blocks. View Logs Stream and filter sandbox logs to monitor agent activity and diagnose policy decisions. Stream sandbox logs: $ openshell logs my-sandbox\nUse flags to filter and follow output: Flag Purpose Example --tail Stream logs in real time openshell logs my-sandbox --tail --source Filter by log source --source sandbox --level Filter by severity --level warn --since Show logs from a time window --since 5m Monitor Your Sandbox OpenShell Terminal is a real-time dashboard that combines sandbox status and live logs in a single view. $ openshell term\nThe dashboard shows the following information. Sandbox status : Name, phase, image, attached providers, age, and active port forwards. Live log stream : Omutbound connections, policy decisions, and inference interceptions as they happen. Logs are labeled by source: sandbox (proxy and policy events) or gateway (lifecycle events). Use the terminal to spot blocked connections ( action=deny entries) and inference interceptions ( action=inspect_for_inference entries). If a connection is blocked unexpectedly, add the host to your network policy — refer to policies for the workflow. Transfer Files Transfer files between your host machine and a running sandbox. Upload files from your host into the sandbox: $ openshell sandbox upload my-sandbox ./src /sandbox/src\nDownload files from the sandbox to your host: $ openshell sandbox download my-sandbox /sandbox/output ./local\nYou can also upload files at creation time with the --upload flag on\nopenshell sandbox create . Delete Sandboxes Remove sandboxes when they are no longer needed. Deleting a sandbox stops all processes, releases cluster resources, and purges injected credentials. Delete a sandbox by name: $ openshell sandbox delete my-sandbox\nDelete all sandboxes in the active gateway: $ openshell sandbox delete --all\nNext Steps Explore related topics: To follow a complete end-to-end example, refer to the /tutorials/github-sandbox tutorial. To supply API keys or tokens, refer to providers . To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog","format":"text","content_length":4956,"word_count":750,"summary":"This page walks you through the full sandbox lifecycle: creating, inspecting, connecting to, monitoring, and deleting sandboxes. For background on what sandboxes are and how the runtime works, refer to About Sandboxes.","headings":[{"text":"Create and Manage Sandboxes","level":1,"id":"create-and-manage-sandboxes"},{"text":"Create a Sandbox","level":2,"id":"create-a-sandbox"},{"text":"Create from a Community Sandbox or Custom Image","level":2,"id":"create-from-a-community-sandbox-or-custom-image"},{"text":"List and Inspect Sandboxes","level":2,"id":"list-and-inspect-sandboxes"},{"text":"Connect to a Sandbox","level":2,"id":"connect-to-a-sandbox"},{"text":"Interactive SSH","level":3,"id":"interactive-ssh"},{"text":"Open in a remote editor","level":3,"id":"open-in-a-remote-editor"},{"text":"View Logs","level":2,"id":"view-logs"},{"text":"Monitor Your Sandbox","level":2,"id":"monitor-your-sandbox"},{"text":"Transfer Files","level":2,"id":"transfer-files"},{"text":"Delete Sandboxes","level":2,"id":"delete-sandboxes"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Create and Manage Sandboxes Create a Sandbox Create from a Community Sandbox or Custom Image List and Inspect Sandboxes Connect to a Sandbox Interactive SSH Open in a remote editor View Logs Monitor Your Sandbox Transfer Files Delete Sandboxes Next Steps","keywords":["about","access","action","agent","check","code","com","community","connect","create","cursor","custom","delete","deleting","docker","dockerfile","download","editor","example","explore","files","filter","flag","from","gateway","gpu","host","image","images","inspect","interactive","launch","lifecycle","like","list","live","logs","manage","monitor","name","next","omutbound","open","openshell","otherwise","output","purpose","reference","remote","remove"],"code_blocks":[{"content":"$ openshell sandbox create -- claude","language":"text"},{"content":"$ openshell sandbox create --gpu -- claude","language":"text"},{"content":"$ openshell sandbox create \\\n --name dev \\\n --provider my-claude \\\n --policy policy.yaml \\\n --upload \\\n -- claude","language":"text"},{"content":"$ openshell sandbox create --from openclaw","language":"text"},{"content":"$ openshell sandbox create --from ./my-sandbox-dir\n$ openshell sandbox create --from my-registry.example.com/my-image:latest","language":"text"},{"content":"$ openshell sandbox list","language":"text"},{"content":"$ openshell sandbox get my-sandbox","language":"text"},{"content":"$ openshell sandbox connect my-sandbox","language":"text"},{"content":"$ openshell sandbox create --editor vscode --name my-sandbox\n$ openshell sandbox connect my-sandbox --editor cursor","language":"text"},{"content":"$ openshell logs my-sandbox","language":"text"},{"content":"$ openshell term","language":"text"},{"content":"$ openshell sandbox upload my-sandbox ./src /sandbox/src","language":"text"},{"content":"$ openshell sandbox download my-sandbox /sandbox/output ./local","language":"text"},{"content":"$ openshell sandbox delete my-sandbox","language":"text"},{"content":"$ openshell sandbox delete --all","language":"text"}],"links":[{"text":"OpenShell Community","type":"external","url":"https://github.com/NVIDIA/OpenShell-Community"}],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Create And Manage"]},{"id":"sandboxes/policies","title":"Customize Sandbox Policies","url":"sandboxes/policies.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Apply, iterate, and debug sandbox network policies with hot-reload on running OpenShell sandboxes.","tags":["Policy","Network Policy","Sandbox","Security","Hot Reload"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Customize Sandbox Policies Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference . Quick Start: Apply a Custom Policy Pass a policy YAML file when creating the sandbox: $ openshell sandbox create --policy ./my-policy.yaml -- claude\nopenshell sandbox create keeps the sandbox running after the initial command exits, which is useful when you plan to iterate on the policy. Add --no-keep if you want the sandbox deleted automatically instead. To avoid passing --policy every time, set a default policy with an environment variable: $ export OPENSHELL_SANDBOX_POLICY=./my-policy.yaml\nopenshell sandbox create -- claude\nThe CLI uses the policy from OPENSHELL_SANDBOX_POLICY whenever --policy is not explicitly provided. Iterate on a Running Sandbox To change what the sandbox can access, pull the current policy, edit the YAML, and push the update. The workflow is iterative: create the sandbox, monitor logs for denied actions, pull the policy, modify it, push, and verify. The following steps outline the hot-reload policy update workflow. Create the sandbox with your initial policy by following Quick Start: Apply a Custom Policy above (or set OPENSHELL_SANDBOX_POLICY ). Monitor denials. Each log entry shows host, port, binary, and reason. Alternatively, use openshell term for a live dashboard. $ openshell logs --tail --source sandbox\nPull the current policy. Strip the metadata header (Version, Hash, Status) before reusing the file. $ openshell policy get --full > current-policy.yaml\nEdit the YAML: add or adjust network_policies entries, binaries, access or rules , or inference.allowed_routes . Push the updated policy. Exit codes: 0 = loaded, 1 = validation failed, 124 = timeout. $ openshell policy set --policy current-policy.yaml --wait\nVerify the new revision. If status is loaded , repeat from step 2 as needed; if failed , fix the policy and repeat from step 4. $ openshell policy list --tail --source sandbox for the denied host, path, and binary. When triaging denied requests, check: Destination host and port to confirm which endpoint is missing. Calling binary path to confirm which binaries entry needs to be added or adjusted. HTTP method and path (for REST endpoints) to confirm which rules entry needs to be added or adjusted. Then push the updated policy as described above. Examples Add these blocks to the network_policies section of your sandbox policy. Apply with openshell policy set --policy --wait\nUse Simple endpoint for host-level allowlists and Granular rules for method/path control. Simple endpoint Allow pip install and uv pip install to reach PyPI: pypi\nname: pypi\nendpoints\nhost: pypi.org\nport: 443\nhost: files.pythonhosted.org\nport: 443\nbinaries\n{ path: /usr/bin/pip\n{ path: /usr/local/bin/uv\nEndpoints without protocol or tls use TCP passthrough — the proxy allows the stream without inspecting payloads. Granular rules Allow Claude and the GitHub CLI to reach api.github.com with per-path rules: read-only (GET, HEAD, OPTIONS) and GraphQL (POST) for all paths; full write access for alpha-repo ; and create/edit issues only for bravo-repo . Replace with your GitHub org or username. For an end-to-end walkthrough that combines this policy with a GitHub credential provider and sandbox creation, refer to /tutorials/github-sandbox . github_repos\nname: github_repos\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nallow\nmethod: GET\npath:\nallow\nmethod: HEAD\npath:\nallow\nmethod: OPTIONS\npath:\nallow\nmethod: POST\npath: \"/graphql\nallow\nmethod:\npath: \"/repos//alpha-repo\nallow\nmethod: POST\npath: \"/repos//bravo-repo/issues\nallow\nmethod: PATCH\npath: \"/repos//bravo-repo/issues\nbinaries\n{ path: /usr/local/bin/claude\n{ path: /usr/bin/gh\nEndpoints with protocol: rest and tls: terminate enable HTTP request inspection — the proxy decrypts TLS and checks each HTTP request against the rules list. Next Steps Explore related topics: To learn about policy structure and network access rules, refer to index . To view the full field-by-field YAML definition, refer to the Policy Schema Reference . To review the default policy breakdown, refer to ../reference/default-policy","format":"text","content_length":4379,"word_count":647,"summary":"Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference.","headings":[{"text":"Customize Sandbox Policies","level":1,"id":"customize-sandbox-policies"},{"text":"Quick Start: Apply a Custom Policy","level":2,"id":"quick-start-apply-a-custom-policy"},{"text":"Iterate on a Running Sandbox","level":2,"id":"iterate-on-a-running-sandbox"},{"text":"Debug Denied Requests","level":2,"id":"debug-denied-requests"},{"text":"Examples","level":2,"id":"examples"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Customize Sandbox Policies Quick Start: Apply a Custom Policy Iterate on a Running Sandbox Debug Denied Requests Examples Next Steps","keywords":["add","allow","alternatively","apply","calling","check","claude","codes","com","create","custom","customize","debug","denied","destination","each","edit","endpoints","enforcement","examples","exit","explore","github","granular","graphql","hash","host","iterate","iterative","method","monitor","name","next","org","pass","path","policies","policy","port","protocol","pull","push","pypi","quick","reference","replace","requests","rules","running","sandbox"],"code_blocks":[{"content":"$ openshell sandbox create --policy ./my-policy.yaml -- claude","language":"text"},{"content":"$ export OPENSHELL_SANDBOX_POLICY=./my-policy.yaml\n$ openshell sandbox create -- claude","language":"text"},{"content":"$ openshell logs --tail --source sandbox","language":"text"},{"content":"$ openshell policy get --full > current-policy.yaml","language":"text"},{"content":"$ openshell policy set --policy current-policy.yaml --wait","language":"text"},{"content":"$ openshell policy list ","language":"text"},{"content":"pypi:\n name: pypi\n endpoints:\n - host: pypi.org\n port: 443\n - host: files.pythonhosted.org\n port: 443\n binaries:\n - { path: /usr/bin/pip }\n - { path: /usr/local/bin/uv }","language":"text"},{"content":"github_repos:\n name: github_repos\n endpoints:\n - host: api.github.com\n port: 443\n protocol: rest\n tls: terminate\n enforcement: enforce\n rules:\n - allow:\n method: GET\n path: \"/**\"\n - allow:\n method: HEAD\n path: \"/**\"\n - allow:\n method: OPTIONS\n path: \"/**\"\n - allow:\n method: POST\n path: \"/graphql\"\n - allow:\n method: \"*\"\n path: \"/repos//alpha-repo/**\"\n - allow:\n method: POST\n path: \"/repos//bravo-repo/issues\"\n - allow:\n method: PATCH\n path: \"/repos//bravo-repo/issues/*\"\n binaries:\n - { path: /usr/local/bin/claude }\n - { path: /usr/bin/gh }","language":"text"}],"links":[{"text":"Quick Start: Apply a Custom Policy","type":"anchor","url":"#quick-start-apply-a-custom-policy"}],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Policies"]},{"id":"sandboxes/providers","title":"Providers","url":"sandboxes/providers.html","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create and manage credential providers that inject API keys and tokens into OpenShell sandboxes.","tags":["Providers","Credentials","API Keys","Sandbox","Security"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Providers AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers . Create and manage providers that supply credentials to sandboxes. Create a Provider Providers can be created from local environment variables or with explicit credential values. From Local Credentials The fastest way to create a provider is to let the CLI discover credentials from\nyour shell environment: $ openshell provider create --name my-claude --type claude --from-existing\nThis reads ANTHROPIC_API_KEY or CLAUDE_API_KEY from your current environment\nand stores them in the provider. With Explicit Credentials Supply a credential value directly: $ openshell provider create --name my-api --type generic --credential API_KEY=sk-abc123\nBare Key Form Pass a key name without a value to read the value from the environment variable\nof that name: $ openshell provider create --name my-api --type generic --credential API_KEY\nThis looks up the current value of $API_KEY in your shell and stores it. Manage Providers List, inspect, update, and delete providers from the active cluster. List all providers: $ openshell provider list\nInspect a provider: $ openshell provider get my-claude\nUpdate a provider’s credentials: $ openshell provider update my-claude --type claude --from-existing\nDelete a provider: $ openshell provider delete my-claude\nAttach Providers to Sandboxes Pass one or more --provider flags when creating a sandbox: $ openshell sandbox create --provider my-claude --provider my-github -- claude\nEach --provider flag attaches one provider. The sandbox receives all\ncredentials from every attached provider at runtime. Providers cannot be added to a running sandbox. If you need to attach an\nadditional provider, delete the sandbox and recreate it with all required\nproviders specified. Auto-Discovery Shortcut When the trailing command in openshell sandbox create is a recognized tool name ( claude , codex , or opencode ), the CLI auto-creates the required\nprovider from your local credentials if one does not already exist. You do not\nneed to create the provider separately: $ openshell sandbox create -- claude\nThis detects claude as a known tool, finds your ANTHROPIC_API_KEY , creates\na provider, attaches it to the sandbox, and launches Claude Code. Supported Provider Types The following provider types are supported. Type Environment Variables Injected Typical Use claude ANTHROPIC_API_KEY , CLAUDE_API_KEY Claude Code, Anthropic API codex OPENAI_API_KEY OpenAI Codex opencode OPENCODE_API_KEY , OPENROUTER_API_KEY , OPENAI_API_KEY opencode tool github GITHUB_TOKEN , GH_TOKEN GitHub API, gh CLI — refer to /tutorials/github-sandbox gitlab GITLAB_TOKEN , GLAB_TOKEN , CI_JOB_TOKEN GitLab API, glab CLI nvidia NVIDIA_API_KEY NVIDIA API Catalog generic User-defined Any service with custom credentials outlook (none: no auto-discovery) Microsoft Outlook integration Use the generic type for any service not listed above. You define the\nenvironment variable names and values yourself with --credential . Next Steps Explore related topics: To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog. To view the complete field reference for the policy YAML, refer to the Policy Schema Reference","format":"text","content_length":3421,"word_count":502,"summary":"AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers.","headings":[{"text":"Providers","level":1,"id":"providers"},{"text":"Create a Provider","level":2,"id":"create-a-provider"},{"text":"From Local Credentials","level":3,"id":"from-local-credentials"},{"text":"With Explicit Credentials","level":3,"id":"with-explicit-credentials"},{"text":"Bare Key Form","level":3,"id":"bare-key-form"},{"text":"Manage Providers","level":2,"id":"manage-providers"},{"text":"Attach Providers to Sandboxes","level":2,"id":"attach-providers-to-sandboxes"},{"text":"Auto-Discovery Shortcut","level":3,"id":"auto-discovery-shortcut"},{"text":"Supported Provider Types","level":2,"id":"supported-provider-types"},{"text":"Next Steps","level":2,"id":"next-steps"}],"headings_text":"Providers Create a Provider From Local Credentials With Explicit Credentials Bare Key Form Manage Providers Attach Providers to Sandboxes Auto-Discovery Shortcut Supported Provider Types Next Steps","keywords":["anthropic","any","attach","auto","bare","catalog","claude","code","codex","create","credentials","delete","directly","discovery","each","environment","explicit","explore","form","from","github","gitlab","injected","inspect","key","list","local","manage","microsoft","name","next","none","openai","openshell","outlook","pass","policy","provider","providers","reference","sandbox","sandboxes","schema","separately","services","shortcut","steps","supply","supported","this"],"code_blocks":[{"content":"$ openshell provider create --name my-claude --type claude --from-existing","language":"text"},{"content":"$ openshell provider create --name my-api --type generic --credential API_KEY=sk-abc123","language":"text"},{"content":"$ openshell provider create --name my-api --type generic --credential API_KEY","language":"text"},{"content":"$ openshell provider list","language":"text"},{"content":"$ openshell provider get my-claude","language":"text"},{"content":"$ openshell provider update my-claude --type claude --from-existing","language":"text"},{"content":"$ openshell provider delete my-claude","language":"text"},{"content":"$ openshell sandbox create --provider my-claude --provider my-github -- claude","language":"text"},{"content":"$ openshell sandbox create -- claude","language":"text"}],"links":[],"images":[],"doc_type":"tutorial","section_path":["Sandboxes","Providers"]}]} \ No newline at end of file diff --git a/pr-preview/pr-291/sandboxes/policies.json b/pr-preview/pr-291/sandboxes/policies.json index 81297c1a9..fa116a27c 100644 --- a/pr-preview/pr-291/sandboxes/policies.json +++ b/pr-preview/pr-291/sandboxes/policies.json @@ -1 +1 @@ -{"id":"sandboxes/policies","title":"Customize Sandbox Policies","url":"sandboxes/policies.html","last_modified":"2026-03-14T00:12:41.761888+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Apply, iterate, and debug sandbox network policies with hot-reload on running OpenShell sandboxes.","tags":["Policy","Network Policy","Sandbox","Security","Hot Reload"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Customize Sandbox Policies Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference . Quick Start: Apply a Custom Policy Pass a policy YAML file when creating the sandbox: $ openshell sandbox create --policy ./my-policy.yaml -- claude\nopenshell sandbox create keeps the sandbox running after the initial command exits, which is useful when you plan to iterate on the policy. Add --no-keep if you want the sandbox deleted automatically instead. To avoid passing --policy every time, set a default policy with an environment variable: $ export OPENSHELL_SANDBOX_POLICY=./my-policy.yaml\nopenshell sandbox create -- claude\nThe CLI uses the policy from OPENSHELL_SANDBOX_POLICY whenever --policy is not explicitly provided. Iterate on a Running Sandbox To change what the sandbox can access, pull the current policy, edit the YAML, and push the update. The workflow is iterative: create the sandbox, monitor logs for denied actions, pull the policy, modify it, push, and verify. The following steps outline the hot-reload policy update workflow. Create the sandbox with your initial policy by following Quick Start: Apply a Custom Policy above (or set OPENSHELL_SANDBOX_POLICY ). Monitor denials. Each log entry shows host, port, binary, and reason. Alternatively, use openshell term for a live dashboard. $ openshell logs --tail --source sandbox\nPull the current policy. Strip the metadata header (Version, Hash, Status) before reusing the file. $ openshell policy get --full > current-policy.yaml\nEdit the YAML: add or adjust network_policies entries, binaries, access or rules , or inference.allowed_routes . Push the updated policy. Exit codes: 0 = loaded, 1 = validation failed, 124 = timeout. $ openshell policy set --policy current-policy.yaml --wait\nVerify the new revision. If status is loaded , repeat from step 2 as needed; if failed , fix the policy and repeat from step 4. $ openshell policy list --tail --source sandbox for the denied host, path, and binary. When triaging denied requests, check: Destination host and port to confirm which endpoint is missing. Calling binary path to confirm which binaries entry needs to be added or adjusted. HTTP method and path (for REST endpoints) to confirm which rules entry needs to be added or adjusted. Then push the updated policy as described above. Examples Add these blocks to the network_policies section of your sandbox policy. Apply with openshell policy set --policy --wait\nUse Simple endpoint for host-level allowlists and Granular rules for method/path control. Simple endpoint Allow pip install and uv pip install to reach PyPI: pypi\nname: pypi\nendpoints\nhost: pypi.org\nport: 443\nhost: files.pythonhosted.org\nport: 443\nbinaries\n{ path: /usr/bin/pip\n{ path: /usr/local/bin/uv\nEndpoints without protocol or tls use TCP passthrough — the proxy allows the stream without inspecting payloads. Granular rules Allow Claude and the GitHub CLI to reach api.github.com with per-path rules: read-only (GET, HEAD, OPTIONS) and GraphQL (POST) for all paths; full write access for alpha-repo ; and create/edit issues only for bravo-repo . Replace with your GitHub org or username. For an end-to-end walkthrough that combines this policy with a GitHub credential provider and sandbox creation, refer to /tutorials/github-sandbox . github_repos\nname: github_repos\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nallow\nmethod: GET\npath:\nallow\nmethod: HEAD\npath:\nallow\nmethod: OPTIONS\npath:\nallow\nmethod: POST\npath: \"/graphql\nallow\nmethod:\npath: \"/repos//alpha-repo\nallow\nmethod: POST\npath: \"/repos//bravo-repo/issues\nallow\nmethod: PATCH\npath: \"/repos//bravo-repo/issues\nbinaries\n{ path: /usr/local/bin/claude\n{ path: /usr/bin/gh\nEndpoints with protocol: rest and tls: terminate enable HTTP request inspection — the proxy decrypts TLS and checks each HTTP request against the rules list. Next Steps Explore related topics: To learn about policy structure and network access rules, refer to index . To view the full field-by-field YAML definition, refer to the Policy Schema Reference . To review the default policy breakdown, refer to ../reference/default-policy","format":"text","summary":"Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference.","headings":[{"text":"Customize Sandbox Policies","level":1},{"text":"Quick Start: Apply a Custom Policy","level":2},{"text":"Iterate on a Running Sandbox","level":2},{"text":"Debug Denied Requests","level":2},{"text":"Examples","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file +{"id":"sandboxes/policies","title":"Customize Sandbox Policies","url":"sandboxes/policies.html","last_modified":"2026-03-14T00:20:51.678174+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Apply, iterate, and debug sandbox network policies with hot-reload on running OpenShell sandboxes.","tags":["Policy","Network Policy","Sandbox","Security","Hot Reload"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_intermediate","audience":["engineer"],"content":"Customize Sandbox Policies Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference . Quick Start: Apply a Custom Policy Pass a policy YAML file when creating the sandbox: $ openshell sandbox create --policy ./my-policy.yaml -- claude\nopenshell sandbox create keeps the sandbox running after the initial command exits, which is useful when you plan to iterate on the policy. Add --no-keep if you want the sandbox deleted automatically instead. To avoid passing --policy every time, set a default policy with an environment variable: $ export OPENSHELL_SANDBOX_POLICY=./my-policy.yaml\nopenshell sandbox create -- claude\nThe CLI uses the policy from OPENSHELL_SANDBOX_POLICY whenever --policy is not explicitly provided. Iterate on a Running Sandbox To change what the sandbox can access, pull the current policy, edit the YAML, and push the update. The workflow is iterative: create the sandbox, monitor logs for denied actions, pull the policy, modify it, push, and verify. The following steps outline the hot-reload policy update workflow. Create the sandbox with your initial policy by following Quick Start: Apply a Custom Policy above (or set OPENSHELL_SANDBOX_POLICY ). Monitor denials. Each log entry shows host, port, binary, and reason. Alternatively, use openshell term for a live dashboard. $ openshell logs --tail --source sandbox\nPull the current policy. Strip the metadata header (Version, Hash, Status) before reusing the file. $ openshell policy get --full > current-policy.yaml\nEdit the YAML: add or adjust network_policies entries, binaries, access or rules , or inference.allowed_routes . Push the updated policy. Exit codes: 0 = loaded, 1 = validation failed, 124 = timeout. $ openshell policy set --policy current-policy.yaml --wait\nVerify the new revision. If status is loaded , repeat from step 2 as needed; if failed , fix the policy and repeat from step 4. $ openshell policy list --tail --source sandbox for the denied host, path, and binary. When triaging denied requests, check: Destination host and port to confirm which endpoint is missing. Calling binary path to confirm which binaries entry needs to be added or adjusted. HTTP method and path (for REST endpoints) to confirm which rules entry needs to be added or adjusted. Then push the updated policy as described above. Examples Add these blocks to the network_policies section of your sandbox policy. Apply with openshell policy set --policy --wait\nUse Simple endpoint for host-level allowlists and Granular rules for method/path control. Simple endpoint Allow pip install and uv pip install to reach PyPI: pypi\nname: pypi\nendpoints\nhost: pypi.org\nport: 443\nhost: files.pythonhosted.org\nport: 443\nbinaries\n{ path: /usr/bin/pip\n{ path: /usr/local/bin/uv\nEndpoints without protocol or tls use TCP passthrough — the proxy allows the stream without inspecting payloads. Granular rules Allow Claude and the GitHub CLI to reach api.github.com with per-path rules: read-only (GET, HEAD, OPTIONS) and GraphQL (POST) for all paths; full write access for alpha-repo ; and create/edit issues only for bravo-repo . Replace with your GitHub org or username. For an end-to-end walkthrough that combines this policy with a GitHub credential provider and sandbox creation, refer to /tutorials/github-sandbox . github_repos\nname: github_repos\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nallow\nmethod: GET\npath:\nallow\nmethod: HEAD\npath:\nallow\nmethod: OPTIONS\npath:\nallow\nmethod: POST\npath: \"/graphql\nallow\nmethod:\npath: \"/repos//alpha-repo\nallow\nmethod: POST\npath: \"/repos//bravo-repo/issues\nallow\nmethod: PATCH\npath: \"/repos//bravo-repo/issues\nbinaries\n{ path: /usr/local/bin/claude\n{ path: /usr/bin/gh\nEndpoints with protocol: rest and tls: terminate enable HTTP request inspection — the proxy decrypts TLS and checks each HTTP request against the rules list. Next Steps Explore related topics: To learn about policy structure and network access rules, refer to index . To view the full field-by-field YAML definition, refer to the Policy Schema Reference . To review the default policy breakdown, refer to ../reference/default-policy","format":"text","summary":"Use this page to apply and iterate policy changes on running sandboxes. For a full field-by-field YAML definition, use the Policy Schema Reference.","headings":[{"text":"Customize Sandbox Policies","level":1},{"text":"Quick Start: Apply a Custom Policy","level":2},{"text":"Iterate on a Running Sandbox","level":2},{"text":"Debug Denied Requests","level":2},{"text":"Examples","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/sandboxes/providers.json b/pr-preview/pr-291/sandboxes/providers.json index 2be3ad337..1bfc6b769 100644 --- a/pr-preview/pr-291/sandboxes/providers.json +++ b/pr-preview/pr-291/sandboxes/providers.json @@ -1 +1 @@ -{"id":"sandboxes/providers","title":"Providers","url":"sandboxes/providers.html","last_modified":"2026-03-14T00:12:41.767293+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create and manage credential providers that inject API keys and tokens into OpenShell sandboxes.","tags":["Providers","Credentials","API Keys","Sandbox","Security"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Providers AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers . Create and manage providers that supply credentials to sandboxes. Create a Provider Providers can be created from local environment variables or with explicit credential values. From Local Credentials The fastest way to create a provider is to let the CLI discover credentials from\nyour shell environment: $ openshell provider create --name my-claude --type claude --from-existing\nThis reads ANTHROPIC_API_KEY or CLAUDE_API_KEY from your current environment\nand stores them in the provider. With Explicit Credentials Supply a credential value directly: $ openshell provider create --name my-api --type generic --credential API_KEY=sk-abc123\nBare Key Form Pass a key name without a value to read the value from the environment variable\nof that name: $ openshell provider create --name my-api --type generic --credential API_KEY\nThis looks up the current value of $API_KEY in your shell and stores it. Manage Providers List, inspect, update, and delete providers from the active cluster. List all providers: $ openshell provider list\nInspect a provider: $ openshell provider get my-claude\nUpdate a provider’s credentials: $ openshell provider update my-claude --type claude --from-existing\nDelete a provider: $ openshell provider delete my-claude\nAttach Providers to Sandboxes Pass one or more --provider flags when creating a sandbox: $ openshell sandbox create --provider my-claude --provider my-github -- claude\nEach --provider flag attaches one provider. The sandbox receives all\ncredentials from every attached provider at runtime. Providers cannot be added to a running sandbox. If you need to attach an\nadditional provider, delete the sandbox and recreate it with all required\nproviders specified. Auto-Discovery Shortcut When the trailing command in openshell sandbox create is a recognized tool name ( claude , codex , or opencode ), the CLI auto-creates the required\nprovider from your local credentials if one does not already exist. You do not\nneed to create the provider separately: $ openshell sandbox create -- claude\nThis detects claude as a known tool, finds your ANTHROPIC_API_KEY , creates\na provider, attaches it to the sandbox, and launches Claude Code. Supported Provider Types The following provider types are supported. Type Environment Variables Injected Typical Use claude ANTHROPIC_API_KEY , CLAUDE_API_KEY Claude Code, Anthropic API codex OPENAI_API_KEY OpenAI Codex opencode OPENCODE_API_KEY , OPENROUTER_API_KEY , OPENAI_API_KEY opencode tool github GITHUB_TOKEN , GH_TOKEN GitHub API, gh CLI — refer to /tutorials/github-sandbox gitlab GITLAB_TOKEN , GLAB_TOKEN , CI_JOB_TOKEN GitLab API, glab CLI nvidia NVIDIA_API_KEY NVIDIA API Catalog generic User-defined Any service with custom credentials outlook (none: no auto-discovery) Microsoft Outlook integration Use the generic type for any service not listed above. You define the\nenvironment variable names and values yourself with --credential . Next Steps Explore related topics: To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog. To view the complete field reference for the policy YAML, refer to the Policy Schema Reference","format":"text","summary":"AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers.","headings":[{"text":"Providers","level":1},{"text":"Create a Provider","level":2},{"text":"From Local Credentials","level":3},{"text":"With Explicit Credentials","level":3},{"text":"Bare Key Form","level":3},{"text":"Manage Providers","level":2},{"text":"Attach Providers to Sandboxes","level":2},{"text":"Auto-Discovery Shortcut","level":3},{"text":"Supported Provider Types","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file +{"id":"sandboxes/providers","title":"Providers","url":"sandboxes/providers.html","last_modified":"2026-03-14T00:20:51.682401+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Create and manage credential providers that inject API keys and tokens into OpenShell sandboxes.","tags":["Providers","Credentials","API Keys","Sandbox","Security"],"topics":["Generative AI","Cybersecurity"],"content_type":"how_to","learning_level":"technical_beginner","audience":["engineer","data_scientist"],"content":"Providers AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers . Create and manage providers that supply credentials to sandboxes. Create a Provider Providers can be created from local environment variables or with explicit credential values. From Local Credentials The fastest way to create a provider is to let the CLI discover credentials from\nyour shell environment: $ openshell provider create --name my-claude --type claude --from-existing\nThis reads ANTHROPIC_API_KEY or CLAUDE_API_KEY from your current environment\nand stores them in the provider. With Explicit Credentials Supply a credential value directly: $ openshell provider create --name my-api --type generic --credential API_KEY=sk-abc123\nBare Key Form Pass a key name without a value to read the value from the environment variable\nof that name: $ openshell provider create --name my-api --type generic --credential API_KEY\nThis looks up the current value of $API_KEY in your shell and stores it. Manage Providers List, inspect, update, and delete providers from the active cluster. List all providers: $ openshell provider list\nInspect a provider: $ openshell provider get my-claude\nUpdate a provider’s credentials: $ openshell provider update my-claude --type claude --from-existing\nDelete a provider: $ openshell provider delete my-claude\nAttach Providers to Sandboxes Pass one or more --provider flags when creating a sandbox: $ openshell sandbox create --provider my-claude --provider my-github -- claude\nEach --provider flag attaches one provider. The sandbox receives all\ncredentials from every attached provider at runtime. Providers cannot be added to a running sandbox. If you need to attach an\nadditional provider, delete the sandbox and recreate it with all required\nproviders specified. Auto-Discovery Shortcut When the trailing command in openshell sandbox create is a recognized tool name ( claude , codex , or opencode ), the CLI auto-creates the required\nprovider from your local credentials if one does not already exist. You do not\nneed to create the provider separately: $ openshell sandbox create -- claude\nThis detects claude as a known tool, finds your ANTHROPIC_API_KEY , creates\na provider, attaches it to the sandbox, and launches Claude Code. Supported Provider Types The following provider types are supported. Type Environment Variables Injected Typical Use claude ANTHROPIC_API_KEY , CLAUDE_API_KEY Claude Code, Anthropic API codex OPENAI_API_KEY OpenAI Codex opencode OPENCODE_API_KEY , OPENROUTER_API_KEY , OPENAI_API_KEY opencode tool github GITHUB_TOKEN , GH_TOKEN GitHub API, gh CLI — refer to /tutorials/github-sandbox gitlab GITLAB_TOKEN , GLAB_TOKEN , CI_JOB_TOKEN GitLab API, glab CLI nvidia NVIDIA_API_KEY NVIDIA API Catalog generic User-defined Any service with custom credentials outlook (none: no auto-discovery) Microsoft Outlook integration Use the generic type for any service not listed above. You define the\nenvironment variable names and values yourself with --credential . Next Steps Explore related topics: To control what the agent can access, refer to policies . To use a pre-built environment, refer to the community-sandboxes catalog. To view the complete field reference for the policy YAML, refer to the Policy Schema Reference","format":"text","summary":"AI agents typically need credentials to access external services: an API key for the AI model provider, a token for GitHub or GitLab, and so on. OpenShell manages these credentials as first-class entities called providers.","headings":[{"text":"Providers","level":1},{"text":"Create a Provider","level":2},{"text":"From Local Credentials","level":3},{"text":"With Explicit Credentials","level":3},{"text":"Bare Key Form","level":3},{"text":"Manage Providers","level":2},{"text":"Attach Providers to Sandboxes","level":2},{"text":"Auto-Discovery Shortcut","level":3},{"text":"Supported Provider Types","level":2},{"text":"Next Steps","level":2}]} \ No newline at end of file diff --git a/pr-preview/pr-291/tutorials/github-sandbox.json b/pr-preview/pr-291/tutorials/github-sandbox.json index a58f1d969..3be9486dc 100644 --- a/pr-preview/pr-291/tutorials/github-sandbox.json +++ b/pr-preview/pr-291/tutorials/github-sandbox.json @@ -1 +1 @@ -{"id":"tutorials/github-sandbox","title":"Set Up a Sandbox of Claude Code with a Custom GitHub Policy","url":"tutorials/github-sandbox.html","last_modified":"2026-03-14T00:12:41.777375+00:00","book":{"title":"NVIDIA OpenShell Developer Guide","version":"0.0.1"},"product":{"name":"OpenShell","version":"0.0.1"},"description":"Learn the iterative policy workflow by launching a sandbox, diagnosing a GitHub access denial, and applying a custom policy to fix it.","tags":["Tutorial","GitHub","Sandbox","Policy","Claude Code"],"topics":["Generative AI","Cybersecurity"],"content_type":"tutorial","learning_level":"technical_intermediate","audience":["engineer"],"content":"Set Up a Sandbox of Claude Code with a Custom GitHub Policy This tutorial walks through an iterative sandbox policy workflow. You launch a sandbox, ask Claude Code to push code to GitHub, and observe the default network policy denying the request\nYou then diagnose the denial from your machine and from inside the sandbox, apply a policy update, and verify that the policy update to the sandbox takes effect. After completing this tutorial, you will have: A running sandbox with Claude Code that can push to a GitHub repository. A custom network policy that grants GitHub access for a specific repository. Experience with the policy iteration workflow: fail, diagnose, update, verify. This tutorial shows example prompts and responses from Claude Code. The exact wording you see might vary between sessions. Use the examples as a guide for the type of interaction, not as expected output. Prerequisites This tutorial requires the following: A working OpenShell installation. Complete the Quickstart before proceeding. A GitHub personal access token (PAT) with repo scope. Generate one from the GitHub personal access token settings page by selecting Generate new token (classic) and enabling the repo scope. An Anthropic account with access to Claude Code. OpenShell provides the sandbox runtime, not the agent. You must authenticate with your own account. A GitHub repository you own to use as the push target. A scratch repository is sufficient. You can create one with a README if needed. This tutorial uses two terminals to demonstrate the iterative policy workflow: Terminal 1 : The sandbox terminal. You create the sandbox in this terminal by running openshell sandbox create and interact with Claude Code inside it. Terminal 2 : A terminal outside the sandbox on your machine. You use this terminal for viewing the sandbox logs with openshell term and applying an updated policy with openshell policy set . Each section below indicates which terminal to use. Set Up a Sandbox with Your GitHub Token Depending on whether you start a new sandbox or use an existing sandbox, choose the appropriate tab and follow the instructions. Starting a new sandbox In terminal 2, create a new sandbox with Claude Code. The default policy is applied automatically, which allows read-only access to GitHub. Create a credential provider that injects your GitHub token into the sandbox automatically. The provider reads GITHUB_TOKEN from your host environment and sets it as an environment variable inside the sandbox: $ GITHUB_TOKEN= with your GitHub organization or username and with your repository name. Prompt Write a hello_world.py script and push it to https://github.com// . Claude recognizes that it needs GitHub credentials. It asks how you want to authenticate. Provide your GitHub personal access token by pasting it into the conversation. Claude configures authentication and attempts the push. The push fails. Claude reports an error, but the failure is not an authentication problem. The default sandbox policy permits read-only access to GitHub and blocks write operations, so the proxy denies the push before the request reaches the GitHub server. Diagnose the Denial In this section, you diagnose the denial from your machine and from inside the sandbox. View the Logs from Your Machine In terminal 2, launch the OpenShell terminal: $ openshell term\nThe dashboard shows sandbox status and a live stream of policy decisions. Look for entries with l7_decision=deny . Select a deny entry to see the full detail: l7_action: PUT\nl7_target: /repos///contents/hello_world.py\nl7_decision: deny\ndst_host: api.github.com\ndst_port: 443\nl7_protocol: rest\npolicy: github_rest_api\nl7_deny_reason: PUT /repos///contents/hello_world.py not permitted by policy\nThe log shows that the sandbox proxy intercepted an outbound PUT request to api.github.com and denied it. The github_rest_api policy allows read operations (GET) but blocks write operations (PUT, POST, DELETE) to the GitHub API. A similar denial appears for github.com if Claude attempted a git push over HTTPS. Ask Claude Code to Check the Sandbox Logs In terminal 1, ask Claude Code to check the sandbox logs for denied requests: Prompt Check the sandbox logs for any denied network requests. What is blocking the push? Claude reads the deny entries and identifies the root cause. It explains that the failure is a sandbox network policy restriction, not a token permissions issue. For example, the following is a possible response: Response The sandbox runs a proxy that enforces policies on outbound traffic\nThe github_rest_api policy allows GET requests (used to read the file\nbut blocks PUT/write requests to GitHub. This is a sandbox-level restriction\nnot a token issue. No matter what token you provide, pushes through the API\nwill be blocked until the policy is updated. Both perspectives confirm the same thing: the proxy is doing its job. The default policy is designed to be restrictive. To allow GitHub pushes, you need to update the network policy. Copy the deny reason from Claude’s response. You paste it into an agent running on your machine in the next step. Update the Policy from Your Machine In terminal 2, paste the deny reason from the previous step into your coding agent on your machine, such as Claude Code or Cursor, and ask it to recommend a policy update. The deny reason gives the agent the context it needs to generate the correct policy rules. After pasting the following prompt sample, properly provide the GitHub organization and repository names of the repository you are pushing to. Prompt Based on the following deny reasons, recommend a sandbox policy update that allows GitHub pushes to https://github.com// , and save to /tmp/sandbox-policy-update.yaml : The filesystem_policy , landlock , and process sections are static. They are read once at sandbox creation and cannot be changed by a hot-reload. They are included here for completeness so the file is self-contained, but only the network_policies section takes effect when you apply this to a running sandbox. The following steps outline the expected process done by the agent: Inspects the deny reasons. Writes an updated policy that adds github_git and github_api blocks that grant write access to your repository. Saves the policy to /tmp/sandbox-policy-update.yaml . Review the Generated Policy Refer to the following policy example to compare with the generated policy before applying it. Confirm that the policy grants only the access you expect. In this case, git push operations and GitHub REST API access scoped to a single repository. Full reference policy The following YAML shows a complete policy that extends the default policy with GitHub access for a single repository. Replace with your GitHub organization or username and with your repository name. The filesystem_policy , landlock , and process sections are static. They are read once at sandbox creation and cannot be changed by a hot-reload. They are included here for completeness so the file is self-contained, but only the network_policies section takes effect when you apply this to a running sandbox. version: 1\n── Static (locked at sandbox creation)\nfilesystem_policy\ninclude_workdir: true\nread_only\n/usr\n/lib\n/proc\n/dev/urandom\n/app\n/etc\n/var/log\nread_write\n/sandbox\n/tmp\n/dev/null\nlandlock\ncompatibility: best_effort\nprocess\nrun_as_user: sandbox\nrun_as_group: sandbox\n── Dynamic (hot-reloadable)\nnetwork_policies\nClaude Code ↔ Anthropic API\nclaude_code\nname: claude-code\nendpoints\n{ host: api.anthropic.com, port: 443, protocol: rest, enforcement: enforce, access: full, tls: terminate\n{ host: statsig.anthropic.com, port: 443\n{ host: sentry.io, port: 443\n{ host: raw.githubusercontent.com, port: 443\n{ host: platform.claude.com, port: 443\nbinaries\n{ path: /usr/local/bin/claude\n{ path: /usr/bin/node\nNVIDIA inference endpoint\nnvidia_inference\nname: nvidia-inference\nendpoints\n{ host: integrate.api.nvidia.com, port: 443\nbinaries\n{ path: /usr/bin/curl\n{ path: /bin/bash\n{ path: /usr/local/bin/opencode\n── GitHub: git operations (clone, fetch, push)\ngithub_git\nname: github-git\nendpoints\nhost: github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nallow\nmethod: GET\npath: \"//.git/info/refs\nallow\nmethod: POST\npath: \"//.git/git-upload-pack\nallow\nmethod: POST\npath: \"//.git/git-receive-pack\nbinaries\n{ path: /usr/bin/git\n── GitHub: REST API\ngithub_api\nname: github-api\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nGraphQL API (used by gh CLI\nallow\nmethod: POST\npath: \"/graphql\nFull read-write access to the repository\nallow\nmethod:\npath: \"/repos// --policy /tmp/sandbox-policy-update.yaml --wait\nNetwork policies are hot-reloadable. The --wait flag blocks until the policy engine confirms the new revision loaded, and the update takes effect immediately without restarting the sandbox or reconnecting Claude Code. Retry the Push In terminal 1, ask Claude Code to retry the push: The sandbox policy has been updated. Try pushing to the repository again\nThe push completes successfully. The openshell term dashboard now shows l7_decision=allow entries for api.github.com and github.com where it previously showed denials. Clean Up When you are finished, delete the sandbox to free cluster resources: $ openshell sandbox delete with your GitHub organization or username and with your repository name. Prompt Write a hello_world.py script and push it to https://github.com// . Claude recognizes that it needs GitHub credentials. It asks how you want to authenticate. Provide your GitHub personal access token by pasting it into the conversation. Claude configures authentication and attempts the push. The push fails. Claude reports an error, but the failure is not an authentication problem. The default sandbox policy permits read-only access to GitHub and blocks write operations, so the proxy denies the push before the request reaches the GitHub server. Diagnose the Denial In this section, you diagnose the denial from your machine and from inside the sandbox. View the Logs from Your Machine In terminal 2, launch the OpenShell terminal: $ openshell term\nThe dashboard shows sandbox status and a live stream of policy decisions. Look for entries with l7_decision=deny . Select a deny entry to see the full detail: l7_action: PUT\nl7_target: /repos///contents/hello_world.py\nl7_decision: deny\ndst_host: api.github.com\ndst_port: 443\nl7_protocol: rest\npolicy: github_rest_api\nl7_deny_reason: PUT /repos///contents/hello_world.py not permitted by policy\nThe log shows that the sandbox proxy intercepted an outbound PUT request to api.github.com and denied it. The github_rest_api policy allows read operations (GET) but blocks write operations (PUT, POST, DELETE) to the GitHub API. A similar denial appears for github.com if Claude attempted a git push over HTTPS. Ask Claude Code to Check the Sandbox Logs In terminal 1, ask Claude Code to check the sandbox logs for denied requests: Prompt Check the sandbox logs for any denied network requests. What is blocking the push? Claude reads the deny entries and identifies the root cause. It explains that the failure is a sandbox network policy restriction, not a token permissions issue. For example, the following is a possible response: Response The sandbox runs a proxy that enforces policies on outbound traffic\nThe github_rest_api policy allows GET requests (used to read the file\nbut blocks PUT/write requests to GitHub. This is a sandbox-level restriction\nnot a token issue. No matter what token you provide, pushes through the API\nwill be blocked until the policy is updated. Both perspectives confirm the same thing: the proxy is doing its job. The default policy is designed to be restrictive. To allow GitHub pushes, you need to update the network policy. Copy the deny reason from Claude’s response. You paste it into an agent running on your machine in the next step. Update the Policy from Your Machine In terminal 2, paste the deny reason from the previous step into your coding agent on your machine, such as Claude Code or Cursor, and ask it to recommend a policy update. The deny reason gives the agent the context it needs to generate the correct policy rules. After pasting the following prompt sample, properly provide the GitHub organization and repository names of the repository you are pushing to. Prompt Based on the following deny reasons, recommend a sandbox policy update that allows GitHub pushes to https://github.com// , and save to /tmp/sandbox-policy-update.yaml : The filesystem_policy , landlock , and process sections are static. They are read once at sandbox creation and cannot be changed by a hot-reload. They are included here for completeness so the file is self-contained, but only the network_policies section takes effect when you apply this to a running sandbox. The following steps outline the expected process done by the agent: Inspects the deny reasons. Writes an updated policy that adds github_git and github_api blocks that grant write access to your repository. Saves the policy to /tmp/sandbox-policy-update.yaml . Review the Generated Policy Refer to the following policy example to compare with the generated policy before applying it. Confirm that the policy grants only the access you expect. In this case, git push operations and GitHub REST API access scoped to a single repository. Full reference policy The following YAML shows a complete policy that extends the default policy with GitHub access for a single repository. Replace with your GitHub organization or username and with your repository name. The filesystem_policy , landlock , and process sections are static. They are read once at sandbox creation and cannot be changed by a hot-reload. They are included here for completeness so the file is self-contained, but only the network_policies section takes effect when you apply this to a running sandbox. version: 1\n── Static (locked at sandbox creation)\nfilesystem_policy\ninclude_workdir: true\nread_only\n/usr\n/lib\n/proc\n/dev/urandom\n/app\n/etc\n/var/log\nread_write\n/sandbox\n/tmp\n/dev/null\nlandlock\ncompatibility: best_effort\nprocess\nrun_as_user: sandbox\nrun_as_group: sandbox\n── Dynamic (hot-reloadable)\nnetwork_policies\nClaude Code ↔ Anthropic API\nclaude_code\nname: claude-code\nendpoints\n{ host: api.anthropic.com, port: 443, protocol: rest, enforcement: enforce, access: full, tls: terminate\n{ host: statsig.anthropic.com, port: 443\n{ host: sentry.io, port: 443\n{ host: raw.githubusercontent.com, port: 443\n{ host: platform.claude.com, port: 443\nbinaries\n{ path: /usr/local/bin/claude\n{ path: /usr/bin/node\nNVIDIA inference endpoint\nnvidia_inference\nname: nvidia-inference\nendpoints\n{ host: integrate.api.nvidia.com, port: 443\nbinaries\n{ path: /usr/bin/curl\n{ path: /bin/bash\n{ path: /usr/local/bin/opencode\n── GitHub: git operations (clone, fetch, push)\ngithub_git\nname: github-git\nendpoints\nhost: github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nallow\nmethod: GET\npath: \"//.git/info/refs\nallow\nmethod: POST\npath: \"//.git/git-upload-pack\nallow\nmethod: POST\npath: \"//.git/git-receive-pack\nbinaries\n{ path: /usr/bin/git\n── GitHub: REST API\ngithub_api\nname: github-api\nendpoints\nhost: api.github.com\nport: 443\nprotocol: rest\ntls: terminate\nenforcement: enforce\nrules\nGraphQL API (used by gh CLI\nallow\nmethod: POST\npath: \"/graphql\nFull read-write access to the repository\nallow\nmethod:\npath: \"/repos// --policy /tmp/sandbox-policy-update.yaml --wait\nNetwork policies are hot-reloadable. The --wait flag blocks until the policy engine confirms the new revision loaded, and the update takes effect immediately without restarting the sandbox or reconnecting Claude Code. Retry the Push In terminal 1, ask Claude Code to retry the push: The sandbox policy has been updated. Try pushing to the repository again\nThe push completes successfully. The openshell term dashboard now shows l7_decision=allow entries for api.github.com and github.com where it previously showed denials. Clean Up When you are finished, delete the sandbox to free cluster resources: $ openshell sandbox delete