pub struct SandboxConfig {
pub secrets: Vec<SecretMapping>,
pub strings: Vec<StringMapping>,
pub connections: Vec<ConnectionPolicy>,
pub allow_private_connect: bool,
pub upstream_ca: Option<PathBuf>,
pub force_traffic_through_proxy: bool,
pub sandbox_backend: Option<SandboxBackend>,
}Expand description
Configuration for the sandbox: secrets, string mappings, connection allow/deny, and proxy options.
Fields§
§secrets: Vec<SecretMapping>Env-based secret mappings (env var name → value). Default empty.
strings: Vec<StringMapping>String token → value mappings. Default empty.
connections: Vec<ConnectionPolicy>Allow/deny rules for outbound connections (host or host regex). Evaluated in order; first match wins; no match = allow. Default empty.
allow_private_connect: boolIf true, CONNECT to private/local addresses (e.g. 127.0.0.1) is allowed. For testing only; default false.
upstream_ca: Option<PathBuf>Optional path to PEM file with extra CA cert(s) to trust for upstream (e.g. self-signed server).
force_traffic_through_proxy: boolIf true, run the child in a sandbox backend (Firecracker on Linux, Docker on macOS) so all traffic is forced through the proxy. Default true.
sandbox_backend: Option<SandboxBackend>Sandbox backend when force_traffic_through_proxy is true. Default: Firecracker on Linux, Docker on macOS.
Trait Implementations§
Source§impl Clone for SandboxConfig
impl Clone for SandboxConfig
Source§fn clone(&self) -> SandboxConfig
fn clone(&self) -> SandboxConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more