exec-server: add optional sandbox start config

Add a typed optional sandbox field to process/start so callers can omit sandboxing for the existing direct-spawn path while reserving a host-default mode for future remote materialization. Reject hostDefault for now instead of silently running unsandboxed, and cover both omitted and explicit sandbox payloads in tests.

Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
starr-openai
2026-03-18 00:18:28 +00:00
parent 28019be4c7
commit 8561abba9a
10 changed files with 1739 additions and 1536 deletions

View File

@@ -121,7 +121,8 @@ Request params:
"PATH": "/usr/bin:/bin"
},
"tty": true,
"arg0": null
"arg0": null,
"sandbox": null
}
```
@@ -133,6 +134,9 @@ Field definitions:
- `tty`: when `true`, spawn a PTY-backed interactive process; when `false`,
spawn a pipe-backed process with closed stdin.
- `arg0`: optional argv0 override forwarded to `codex-utils-pty`.
- `sandbox`: optional sandbox config. Omit it for the current direct-spawn
behavior. Explicit `{"mode":"none"}` is accepted; `{"mode":"hostDefault"}`
is currently rejected until host-local sandbox materialization is wired up.
Response: