Skip to content

Commit 7666b79

Browse files
committed
docs
1 parent 3695796 commit 7666b79

File tree

1 file changed

+11
-15
lines changed

1 file changed

+11
-15
lines changed

docs/tutorials/first-network-policy.md

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,19 @@ title:
44
nav: First Network Policy
55
description: See how OpenShell network policies work by creating a sandbox, observing default-deny in action, and applying a fine-grained L7 read-only rule.
66
topics:
7-
- Generative AI
8-
- Cybersecurity
7+
- Generative AI
8+
- Cybersecurity
99
tags:
10-
- Tutorial
11-
- Policy
12-
- Network Policy
13-
- Sandbox
14-
- Security
10+
- Tutorial
11+
- Policy
12+
- Network Policy
13+
- Sandbox
14+
- Security
1515
content:
1616
type: tutorial
1717
difficulty: technical_beginner
1818
audience:
19-
- engineer
19+
- engineer
2020
---
2121

2222
<!--
@@ -38,6 +38,7 @@ After completing this tutorial, you understand:
3838
## Prerequisites
3939

4040
- A working OpenShell installation. Complete the {doc}`/get-started/quickstart` before proceeding.
41+
- Docker Desktop running on your machine.
4142

4243
:::{tip}
4344
To run every step of this tutorial, you can also use the automated demo script at the [examples/sandbox-policy-quickstart](https://github.com/NVIDIA/OpenShell/blob/main/examples/sandbox-policy-quickstart) directory in the NVIDIA OpenShell repository. It runs the full walkthrough in under a minute but without any user interaction.
@@ -149,7 +150,7 @@ This tutorial uses `curl` and `read-only` access to keep things simple. When bui
149150
- To scope the policy to an agent, replace the `binaries` section with your agent's binary, such as `/usr/local/bin/claude`, instead of `curl`.
150151
- To grant write access, change `access: read-only` to `read-write` or add explicit `rules` for specific paths. Refer to the {doc}`/reference/policy-schema`.
151152
- To allow additional endpoints, stack multiple policies in the same file for PyPI, npm, or your internal APIs. Refer to {doc}`/sandboxes/policies` for examples.
152-
:::
153+
:::
153154

154155
## Verify If GET Requests Are Allowed
155156

@@ -182,11 +183,7 @@ $ curl -s -X POST https://api.github.com/repos/octocat/hello-world/issues \
182183
```
183184

184185
```json
185-
{
186-
"error": "policy_denied",
187-
"policy": "github-api-readonly",
188-
"detail": "POST /repos/octocat/hello-world/issues not permitted by policy"
189-
}
186+
{"error":"policy_denied","policy":"github-api-readonly","detail":"POST /repos/octocat/hello-world/issues not permitted by policy"}
190187
```
191188

192189
The CONNECT request succeeded because `api.github.com` is allowed, but the L7 proxy inspected the HTTP method and returned `403`. `POST` is not in the `read-only` preset. An agent with this policy can read code from GitHub but cannot create issues, push commits, or modify anything.
@@ -229,7 +226,6 @@ To run this entire walkthrough non-interactively, use the automated demo script:
229226
```console
230227
$ bash examples/sandbox-policy-quickstart/demo.sh
231228
```
232-
233229
:::
234230

235231
## Next Steps

0 commit comments

Comments
 (0)