Skip to content

ProcFSOpts

Defined in: packages/core/src/kernel/fileservers/proc.ts:158

Options bag for procFS.

Every field is optional and gates a specific feature of the resulting fileserver. procFS produces the minimal read-only projection of the process table when called with no opts; each callback adds a capability that depends on the kernel being fully wired (hence the forward-reference pattern in createContainerKernel).

procFS

optional getNs?: (pid) => string

Defined in: packages/core/src/kernel/fileservers/proc.ts:181

Renders the namespace-mount projection for /proc/<pid>/ns. When absent, the ns file is hidden from /proc/<pid>/ listings and not openable. The returned string is written verbatim to any reader. The runtime supplies a newline-terminated list of mount points (with “(union: N)” annotations where multiple servers are bound to the same path).

Pid

string


optional getSuspended?: (pid) => boolean

Defined in: packages/core/src/kernel/fileservers/proc.ts:188

Reports whether a process is currently suspended so /proc/<pid>/status can emit state: suspended (rather than the raw Process.state). Suspension is a kernel-side concept above the process table; absent this hook, status lines fall back to the table’s unfiltered state field.

Pid

boolean


optional log?: KernelLog

Defined in: packages/core/src/kernel/fileservers/proc.ts:165

Kernel log ring buffer to project as /proc/log. When absent, /proc/log does not appear in the /proc directory listing and open('/proc/log') throws ENOENT. Each open() snapshots the buffer’s current entries and serializes them as <pri>[time] pid:N msg\n lines.


optional signal?: (pid, sig) => void

Defined in: packages/core/src/kernel/fileservers/proc.ts:173

Signal-delivery function wired into the /proc/<pid>/ctl writable file. When absent, ctl is omitted from /proc/<pid>/ listings and writes have nowhere to dispatch. When present, writing kill / term / hup / int to ctl translates to the corresponding SIGKILL / SIGTERM / SIGHUP / SIGINT delivered via this callback.

Pid

Signal

void