pub struct SandboxConfig {
pub add_current_working_directory: Option<bool>,
pub allow_dev_tool_access: Option<bool>,
pub auth: Option<SandboxConfigAuth>,
pub enabled: bool,
pub user_policy: Option<SandboxConfigUserPolicy>,
}Expand description
Resolved sandbox configuration.
Experimental. This type is part of an experimental wire-protocol surface and may change or be removed in future SDK or CLI releases.
Fields§
§add_current_working_directory: Option<bool>Whether to auto-add the current working directory to readwritePaths. Default: true.
allow_dev_tool_access: Option<bool>Whether to auto-grant read access to the tool directories discovered on PATH and in toolchain environment variables (GOROOT, CARGO_HOME, JAVA_HOME, VIRTUAL_ENV, and similar), and to common developer-tool caches, registries, and toolchains in their default home locations (cargo, go, npm, Maven, and more), plus read-write access to (and up-front creation of) the scratch caches builds write on every run (go-build, ccache, sccache, Gradle caches, Cargo lock/tracker files), so builds work without extra configuration; a relocated CARGO_HOME additionally gets its Cargo lock files granted read-write. Set to false to disable every grant listed above: user-installed toolchains (rustup, nvm, pyenv, conda, pipx) then need explicit userPolicy.filesystem entries — readonlyPaths to read them, plus readwriteFiles for a relocated CARGO_HOME’s .package-cache and .global-cache, which Cargo locks on every build. Only these developer-tool grants are affected: the working directory (see addCurrentWorkingDirectory), temporary storage, session log paths, and system locations follow their own rules and stay granted, so commands still run. Default: true (enabled by default; set to false to opt out).
auth: Option<SandboxConfigAuth>Credential-injection capability flags.
enabled: boolWhether sandboxing is enabled for the session.
user_policy: Option<SandboxConfigUserPolicy>User-managed sandbox policy fragment merged into the auto-discovered base policy.
Trait Implementations§
Source§impl Clone for SandboxConfig
impl Clone for SandboxConfig
Source§fn clone(&self) -> SandboxConfig
fn clone(&self) -> SandboxConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more