code wiki / (root) / nx_container_run_test.nx

nx_container_run_test.nx

buildroot/runtime/nx_container_run_test.nx

1954 B46 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind gate/prooftopic container
docsdependenciesstructsconstsfunctions

about

nx_container_run_test.nx -- proof that nx_container (sovereign Docker replacement) actually RUNS a process: run /tmp/nx_exit42.sov.elf in UTS+IPC+mount namespaces (rootfs="/" => no chroot, sees real FS) and assert the container captured its exit code (42). Needs root for unshare. expect_exit: 0 (0 == container ran the process and got exit_code 42) license_tier: ORIGINAL (direct import "nx_syscalls.nx" REMOVED 2026-07-31, debt 1785528831: this file also imports nx_container.nx which imports nx_syscalls_x86_64.nx, so the direct import put TWO syscall layers in one TU -- every wrapper twice, picked by definition ORDER. The syscalls it needs arrive via nx_container.nx, and the raw x86 numbers 165/161/272 pass through the backend translator correctly. Verified by reading emitted asm, not exit codes.)

dependencies 1 imports · 0 importers

nx_container.nx nx_container_run_test.nx

imports: nx_container.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main nx_container_run sys_fork _child_setup_and_exec sys_unshare sys_chroot _path_proc_abs _str_proc _str_none sys_mount sys_execve sys_wait4

structs

none

consts

14const CLONE_NEWNS: i64 = 0x00020000
15const CLONE_NEWUTS: i64 = 0x04000000
16const CLONE_NEWIPC: i64 = 0x08000000

functions

18func main() -> i64