Skip to main content

Crate kot

Crate kot 

Source
Expand description

kot: an OCI container runtime.

One crate, in layers. sys is the syscall boundary, and the only place that issues syscall instructions. seccomp, cgroup and oci sit on it and know nothing about each other: a filter compiler, a control group manager, and the specification with the plan it lowers to. linux is the half that runs inside the container. The modules beside this file are the runtime itself, the part a caller drives.

Modules§

cgroup
cgroup management for the kot runtime.
cli
Command line parsing.
json
Writing the JSON the runtime’s callers parse.
log
Diagnostics.
oci
Reading, validating and lowering the OCI runtime configuration.
rdt
Cache and memory-bandwidth partitioning, through resctrl.
report
Rendering the reports the commands print.
seccomp
A classic-BPF seccomp filter compiler.
stats
What a container is using, and the events a supervisor watches for.
sys
The syscall boundary for the kot runtime.
validate
Checking a configuration before any of it is applied.

Constants§

EXEC_FAILURE
Exit code for an exec that never reached the process it was asked to run.
FAILURE
Exit code for a runtime failure.

Functions§

cgroup_for
Opens the cgroup manager a container was created with.
failure_code
The code to exit with when a command line failed.
now
The current time, as the timestamp the state record carries.
observed_status
The status to report to a caller, including whether the container is frozen.
owner
Who created a container, for the state record.
refine_status
The same answer for a caller that already established whether the container is alive.
run
Runs one command line and returns the code the caller should exit with.
wait_for_process
Waits for a process and returns the exit code a caller should see.