Skip to content

Latest commit

 

History

History
70 lines (68 loc) · 13.1 KB

roadmap.md

File metadata and controls

70 lines (68 loc) · 13.1 KB

Roadmap

Roadmap

  • Runtime service loading — schema-ctl add <path> loads a new service at runtime
  • Runtime reload + removal — schema-ctl reload [--evict] re-reads config (cycle-checked); --evict SIGTERMs services dropped from config, no reboot
  • login1 D-Bus stub — schema-logind restores KDE shutdown/restart buttons on no-systemd systems
  • event-driven main loop — signalfd for SIGCHLD + poll() with 250ms timeout; wakes on child death and ctl commands instead of busy-polling
  • Boot hang fix — dep_idx alignment bug in group dep resolution; poll() replaces epoll (PID 1 epoll deadlock on kernel 6.1.0-49)
  • Boot timing — schema-ctl timing reports kernel→PID1 handoff and per-service FUNDAMENTAL/PERFECT timestamps (CLOCK_MONOTONIC)
  • Boot time measurement — 29.5s → 20.7s with ready_path probes; stable_secs fallback per service
  • Per-service readiness probes — ready_path= promotes on path existence; stable_secs= fallback timer
  • Cgroup assignment race fix — pipe barrier guarantees cgroup.procs written before child exec
  • Dynamic poll timeout — loop sleeps indefinitely once all services stable; 0% CPU idle
  • Service log files — stdout/stderr per service at /run/log/schema-init/<name>.log
  • D-Bus stubs — hostname1 and systemd1 Manager stubs in schema-logind; KDE Settings 25s → 2s
  • Fedora KDE distribution — GreyBox daily driver, full KDE Plasma 6 on Fedora 44
  • Fedora Cinnamon distribution — Eli (Dell Inspiron), keyboard/touchpad/ethernet working
  • STATE_DORMANT (75) — exponential backoff before 76 verdict; critical services never excise
  • Soft dep cascades — non-critical EXCISED deps skipped; dependents proceed without them
  • aarch64 cross-compile — make aarch64; all three binaries static; Ungulate Leg target ready
  • ARM bare-metal deploy — Pi Zero W (armv6l), Pi OS Trixie; SSH up in ~50s from cold boot
  • schema-desktop — SDL2 live service viewer; make desktop + autostart entry in Cinnamon and KDE distros
  • Dead Man Token hardware watchdog — /dev/watchdog driven by per-service check-in via schema-ctl pet; any critical service missing its watchdog_timeout_ms window stops WDT petting → hardware reboot; PID 1 deadlock covered implicitly
  • Symlink template instances — motor@12.svc → motor@.svc; $INSTANCE injected at spawn; $SLOT_ID fallback for GPIO-strapped nodes; one SD card image per fleet
  • Structured telemetry — schema-ctl status --json and --kv for machine-parseable supervisory loop consumption and IEC 62304 audit traceability
  • Cgroup resource limits — cpu_limit= (1–100, % of one core), mem_limit= (MB), cpuset= (CPU affinity / core pinning, systemd AllowedCPUs= analog), and cpuset_partition= (isolated/root exclusive cores via cgroupv2 partitions — dynamic isolcpus) per .svc; written via sync-pipe window before child exec; IEC 62304 Class C blast-radius isolation
  • zram swap — zram-swap.svc boots a zstd-compressed zram swap device, replacing systemd's zram-generator; eliminates disk thrashing / periodic stutter under memory pressure
  • schema-udev — native .dev-rule device manager with an authoritative cutover that retires systemd-udevd and owns /dev: node creation, the /dev/disk/by-* + /dev/char + /dev/block symlink farm, uaccess seat ACLs, the libudev monitor broadcast, and the /run/udev/data database — checksum-backed, reversible, guarded by a headless seatbelt
  • schema-udev hotplug workers — each live uevent runs in a forked worker; events for one device (path, ancestors, device number, ifindex) stay in order while unrelated devices proceed, with a 30 s per-helper and 180 s per-event deadline, so one stuck device never freezes hotplug (udevd parity)
  • schema-journal-sink — a journald-shaped endpoint (schema-journal-sink.c) that drains /dev/log to a plain per-service logfile with a journalctl shim; no journal database
  • schema-logind consolidation — one schema-logind process now serves login1 and the hostname1 / timedate1 / locale1 surfaces (sessions, seats, power, hostname, RTC/timezone, locale) — the "little-4" in a single readable program
  • schema-systemd1 — the full org.freedesktop.systemd1 management surface (ListUnits, GetUnit, Start/Stop/RestartUnit, per-unit ActiveState/SubState/MainPID/NRestarts, PropertiesChanged) served by its own schema-systemd1 process driving schema-ctl; systemctl status and Cockpit's Services page work
  • Built-in .svc timers — on_calendar= scheduling parsed in service.c retires cron and systemd .timer units (richer calendar forms tracked in docs/timers-design.md)
  • In-place migrator + COPR — schema-migrate --discover/--deploy/--uninstall converts a live Fedora KDE box to schema-init as PID 1 and back (proven end-to-end in a VM); prebuilt via dnf copr enable ajax80/schema-init (three packages), with a guided schema-init-wizard GUI
  • schema-dbus — native C broker replacing dbus-daemon on both the system bus and the session bus; enforces the dissolved busconfig policy (conformance-tested), does auth / name ownership / routing / match rules / unix-fd passing; serves a full KDE desktop as the live bus through reboots; opt-in, self-healing, reversible flip (on-demand activation, BecomeMonitor, full driver interface)
  • systemctl compat translator — a schema-systemctl shim (systemctl_shim.h) that makes packaged RPM/deb scriptlets (systemctl enable/daemon-reload/…) succeed on a schema-init box and records enable-intent to pending.list, plus a schema-import runtime importer that drains the queue and translates .service units into native .svc (ExecStart/Type/Restart/User/Environment with $VAR resolution, Type=notify → notify=1, Type=dbus → ready_bus_name=; Type=forking + PIDFile= → pid_file=; templates logged-and-skipped); dnf install/remove round-trip verified, generated units load under the real .svc parser
  • modules-load.d — PID 1 hands the *.conf drop-ins in /etc, /run, /usr/local/lib, /usr/lib and /lib modules-load.d (same-name override and /dev/null masking as systemd) to one modprobe -a -b child early in boot and holds the first spawn until it exits (systemd-modules-load parity)
  • Static device nodes — PID 1 creates the modules.devname nodes (/dev/net/tun, /dev/uinput, /dev/vhost-net …) and applies static-nodes-permissions.conf at boot, so first open autoloads the module (kmod-static-nodes + tmpfiles-setup-dev parity)
  • schema-doctor — health checks with self-heal (boot-entry integrity, NM profiles bound to missing interfaces, session agents, powerdevil / ksycoca loops, panel pins), run at boot and periodically
  • Boot snapshots + GRUB fallback — known-good root snapshots with their own boot entries (separate /boot, initramfs and non-fstab /home handled) and a boot-success guard
  • PID 1 re-exec — schema-ctl reexec swaps the init binary in place with a dry run, sealed state handoff and rollback; RPM upgrades re-exec automatically, so updating PID 1 is just dnf upgrade, no reboot
  • Service watchdog — watchdog_sec= with WATCHDOG=1 over sd_notify (systemd WatchdogSec= parity): missed window → SIGABRT + core, then SIGKILL, then the normal restart arc
  • Fedora 44 installer ISO, verified on real hardware — netinst + kickstart installs KDE on schema-init as PID 1 with an optional guided schema-udev flip; clean install to desktop on a Dell i3 laptop with no hand fixes (v0.3.0)
  • Per-user supervisor — schema-user, one per logged-in user and per lingering user from boot, started, supervised, stopped and adopted by schema-logind; schema-ctl --user; schema-import --user runs the user's enabled systemd user units (socket/timer service deps, ConditionUser=, network-online wait); a systemctl --user shim; session D-Bus activation routed through it; org.freedesktop.systemd1 on the session bus (schema-systemd1-session)
  • Per-user supervisor, phase 2 — session targets, a native session systemd1 with scopes, and verified GNOME, rootless podman/Quadlet and per-app scopes
  • Landlock TCP rules — landlock_bind_tcp= / landlock_connect_tcp=: the kernel limits which TCP ports a service may listen on and connect to, with no firewall and no eBPF
  • Rootless podman + Quadlet on schema-user — .container files run as supervised user services (boot with lingering — first boot showed the start held about 60 s by the nm-online wait, restart on crash, limits verified, LAN ports); spec docs/superpowers/specs/2026-10-27-rootless-podman-quadlet-design.md
  • podman exec from a login shell — podman's own podman-<pid>.scope request honoured (session shim + root AttachProcessesToUnit, own processes only); spec docs/superpowers/specs/2026-11-03-podman-exec-scopes-design.md
  • schema-user re-adopts running services across its own restart, so containers survive an upgrade — schema-ctl --user reexec swaps the binary in place (the shared PID 1 re-exec), and a package upgrade does it for every running instance
  • Alpine port — distros/alpine/ beside OpenRC, built on the musl support from the Void musl port
  • schema-ctl polish — schema-top (live status over ssh from the shared-memory table, per-service memory and CPU from cgroups), colour in schema-ctl status on a terminal, and schema-ctl log [-f] <svc> (the dependency graph as text is schema-ctl graph)
  • schema-import: SocketBindDeny= all TCP + SocketBindAllow= ports → landlock_bind_tcp= (port 0 kept for ephemeral binds, as systemd does); deny-lists, UDP rules and sets of more than 15 ports are warned, not translated
  • schema-logind in C (shelved) — rewrite schema-logind.py (~127 KB of Python) in C as schema-dbus was. Measured: it would save 0–1 s of boot (logind is often off the critical path) and ~27 MB RSS, and the system still needs Python for schema-systemd1.py and dnf. Revisit only for a minimal distro target, porting logind and schema-systemd1 together
  • btrfs device scan — schema-mount-fstab runs btrfs device scan before mounting a btrfs entry, so a multi-device btrfs mounts when fstab runs alongside coldplug (Artix)
  • Descriptor store — fdstore=N: a service hands its sockets and client fds to PID 1 before it stops and gets them back on restart; schema-dbus restarts without dropping a client
  • restart_sec= — a wait between a death and the respawn (systemd RestartSec=)
  • schema-dbus live config reload — new or changed D-Bus config applies on its own (inotify, debounced), on SIGHUP and on ReloadConfig, with the policy re-dissolved off the event loop and sanity-checked before it goes live; systemctl reload dbus from a package scriptlet reloads, never restarts the bus
  • Full audit (Nov 2026) — stricter .svc parsing, hardened static-pie builds, the journal sink and control socket made hostile-input safe, logind seat trust, /run and /dev/shm caps, opt-in hardware watchdog, mem_low=/swap_max=, parallel fsck, parallel udev hotplug workers (v0.4.26)
  • exec_reload= / reload_signal= and schema-ctl reload <svc> — systemctl reload and D-Bus ReloadUnit reload instead of restarting; importer maps ExecReload= and Type=notify-reload
  • restart= (systemd's seven Restart= values), success_exit_status=, restart_prevent_exit_status=
  • kill_mode= (control-group / mixed / process), kill_signal=, final_kill_signal=; a runtime stop escalates after its grace
  • runtime_dir= / state_dir= / cache_dir= / logs_dir= — created by PID 1 owned by the service user, never through a symlink; runtime ones removed on stop; importer maps RuntimeDirectory= and friends without using exec_pre slots
  • Kernel-surface hardening knobs — protect_kernel_tunables, protect_kernel_modules, protect_control_groups, private_devices, private_network, protect_hostname, restrict_suid_sgid, memory_deny_write_execute, umask
  • Scheduling — nice=, io_class=/io_priority=, sched_policy=/sched_priority=
  • watch_path= (systemd .path units) — exists/exists_glob/dir_not_empty/changed/modified on PID 1's inotify fd, make_directory=, trigger limit; importer takes .path units
  • randomized_delay_sec= and richer on_calendar= (weekday/day lists and ranges, hour/minute steps, up to 4 lines); importer maps RandomizedDelaySec=, OnActiveSec=, wall-aligned hourly
  • supplementary_groups=, dynamic_user=1 — allocated uid, private state dirs behind a namespace tmpfs; importer maps DynamicUser= (earlyoom no longer runs as root) and SupplementaryGroups=
  • syscall_filter= (seccomp) — hand-built BPF for a static PID 1 with systemd's named syscall groups, plus restrict_suid_sgid, lock_personality, restrict_realtime, restrict_namespaces; blocked calls get EPERM
  • syscall_deny= — a denylist preset (on the 4.6 engine), opt-in per service — taken out from under the hardening-default switch after it cut mount(2) from every unpinned host .svc on blakbox (11-18)