Skip to content

Commit cfae2e8

Browse files
authored
Merge pull request #25908 from nielskaspers/docs/issue-25907-env-file-placement
docs(sandboxes): clarify environment file placement across mounted workspaces
2 parents 89c4116 + b47f522 commit cfae2e8

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

content/manuals/ai/sandboxes/configuration/environment-files.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ setup steps.
3131
## Start an environment
3232

3333
Keep the environment file outside the directories you mount into the sandbox.
34+
That includes the primary workspace and every `additionalWorkspaces` mount.
3435
For example, place it beside your project:
3536

3637
```text
@@ -73,7 +74,9 @@ named `web-app`, installs Playwright and Chromium, and publishes sandbox port
7374
existing sandbox.
7475

7576
This placement keeps the environment file outside the agent's writable
76-
workspace. See the [`workspace` guidance](#workspace) for details.
77+
workspace. If you later add `additionalWorkspaces`, keep `.sbxenv.yaml`
78+
outside those directories too. See the [`workspace` guidance](#workspace)
79+
for details.
7780

7881
## Commands
7982

@@ -263,7 +266,8 @@ clone mode:
263266
> With [direct mount](../security/isolation.md#direct-mount-default), the agent can
264267
> modify every file in a workspace. If an environment file is inside a mounted
265268
> workspace, the agent can change the file that controls later `sbx env`
266-
> commands. Store environment files outside all direct-mounted workspaces.
269+
> commands. Store environment files outside all direct-mounted workspaces,
270+
> including every `additionalWorkspaces` mount.
267271
> [Clone mode](../security/isolation.md#clone-mode) protects files in the primary
268272
> repository, but additional workspaces remain direct-mounted.
269273

0 commit comments

Comments
 (0)