pub struct KernelOptions {
pub cwd: PathBuf,
pub runtime_path: PathBuf,
pub python: Option<PathBuf>,
pub startup_timeout: Duration,
pub limits: LimitOverrides,
pub env: Vec<(String, String)>,
pub snapshot_path: Option<PathBuf>,
pub snapshot_key: Option<Vec<u8>>,
pub continuity: Option<ContinuityPolicy>,
pub sandbox: Option<Arc<Launcher>>,
pub tree_memory: Option<TreeMemoryOptions>,
pub base_env: Option<Vec<(String, String)>>,
}Fields§
§cwd: PathBuf§runtime_path: PathBuf§python: Option<PathBuf>Interpreter; default ULTRON_PYTHON, else /usr/bin/python3 when it exists, else python3.
startup_timeout: DurationBounds initialization, not execution.
limits: LimitOverridesOverrides ULTRON_RLM_MAX_MEMORY_MB / ULTRON_RLM_MAX_CPU_SECONDS; 0 disables a limit.
env: Vec<(String, String)>Extra environment for the kernel, applied after the credential filter.
snapshot_path: Option<PathBuf>The default path of Kernel::snapshot / Kernel::restore; a new kernel restores it before its first
call (kernel.ts snapshotPath).
snapshot_key: Option<Vec<u8>>HMAC key that signs and verifies snapshots in the host; the kernel never receives it. Default: a key of this process, so snapshots then restore only within it.
continuity: Option<ContinuityPolicy>Checkpoint after cells and recover from kernel death; requires snapshot_path.
sandbox: Option<Arc<Launcher>>Start runtime.py inside this launcher’s sandbox (the session’s bash policy, plus the snapshot and spill
directories writable and the interpreter readable), so a cell’s direct open() is contained too. Docker
cannot carry the protocol descriptors: with it (or nothing working) auto runs unsandboxed and required
refuses to start. None: unsandboxed.
tree_memory: Option<TreeMemoryOptions>The whole-tree memory cap (kernel.ts maxTreeMemoryMb / treeMemoryBackend); None: no tree cap.
base_env: Option<Vec<(String, String)>>The environment the kernel starts from (before the credential filter) and where its ULTRON_* settings
(ULTRON_PYTHON, limits, output budget, tree memory) are read: a session’s own environment, so the kernel
never sees the server process’s PATH or variables. None: this process’s environment.