internal

package
v0.5.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 7, 2026 License: MIT Imports: 41 Imported by: 0

Documentation

Index

Constants

View Source
const ControlSocket = "/run/sv.sock"

ControlSocket is the Unix socket PID 1 serves for the `sv` service-control CLI. It is root-only (0600).

Variables

View Source
var DefaultReaper = reaper.DefaultReaper

DefaultReaper is the process-wide reaper (see reaper.DefaultReaper).

Functions

func ConfigureStaticNetwork

func ConfigureStaticNetwork(iface, ipCIDR, gateway string, dns []string) error

func ConfiguredConsoles

func ConfiguredConsoles(cfg *Config) []string

ConfiguredConsoles returns the ttys to run a console getty on. If rc.conf sets `CONSOLES` (whitespace-separated, e.g. "tty0 ttyAMA0"), that list is used verbatim. Otherwise the default is tty0 (the virtual console) plus whatever serial console the kernel was told to use on its cmdline (`console=`) — so a graphical console and a headless/serial deployment both get a login, and we use the arch's real serial device (ttyAMA0 on arm64, ttyS0 on amd64) rather than guessing from a static list (the 8250 driver pre-creates phantom /dev/ttyS0..3 nodes on arm64 that aren't real ports, so device-node existence can't tell a usable serial port from a stub — the kernel's own console= can).

func CreateDevices

func CreateDevices() error

func DHCPClient

func DHCPClient(ifname string, onBound ...func(*dhclient.Lease)) (*dhclient.Client, error)

func ErrInvalidCfgFile

func ErrInvalidCfgFile(cfgFile string) error

func ErrNotExists

func ErrNotExists(fieldName string) error

func ExitStatus

func ExitStatus(ws unix.WaitStatus) int

func FormatUptime

func FormatUptime(d time.Duration) string

func Gettys

func Gettys(ctx context.Context, ttys []string, persist bool)

Gettys spawns a getty on each named tty (e.g. "tty0", "ttyS0", "ttyAMA0") whose device node exists, so an explicitly-configured console with no node at all is skipped rather than left error-looping. If persist is true, each surviving getty is respawned when it exits.

func InterfaceUp

func InterfaceUp(ifname string) error

func Mkdev

func Mkdev(major, minor int) int

Mkdev is used to build the value of linux devices (in /dev/) which specifies major and minor number of the newly created device special file. Linux device nodes are a bit weird due to backwards compat with 16 bit device nodes. They are, from low to high: the lower 8 bits of the minor, then 12 bits of the major, then the top 12 bits of the minor.

func Mknod

func Mknod(path string, mode uint32, dev int) error

Mknod creates a filesystem node (file, device special file or named pipe) named path with attributes specified by mode and dev.

func NewSSHServer

func NewSSHServer(bind, keys string, opts ...option) (*server, error)

func ParseServiceConfigs

func ParseServiceConfigs(dir string) (map[ServiceType][]*Service, error)

Parses all the config in directory dir return a map of providers of ServiceTypes from that directory.

func RunReaper

func RunReaper()

func ScanDevices

func ScanDevices(ctx context.Context) error

ScanDevices walks /sys/devices for the existing (cold-plugged) devices and populates /dev, the udev coldplug that has to finish before gettys start (they need their tty nodes). It dominated boot time as a single-threaded walk that read every `uevent` file in series, so this does it concurrently: collect the uevent paths (a cheap readdir-only pass), then read/parse them and mknod the nodes in a worker pool. The cost is the per-file sysfs reads, which are independent and syscall-bound, so overlapping them across CPUs roughly halves the phase. addDevice only ever touches distinct /dev paths and os.MkdirAll/ Mknod tolerate concurrency, so the parallelism is safe; the resulting set of nodes is identical to the serial scan.

func ServeControl

func ServeControl(sup *Supervisor) error

ServeControl creates the control socket and serves it in the background, dispatching requests to the supervisor. It returns once the listener is up.

func SetupFirewall

func SetupFirewall(sshPort uint16, containerBridge string) error

SetupFirewall installs a conservative baseline nftables policy: a single `inet gonix_filter` table with an input chain whose policy is drop, but which accepts loopback, established/related connections, SSH, ICMP/ICMPv6, and anything arriving on the container bridge (so box containers can still reach host services such as DNS). The forward and output paths are left untouched, so box's own NAT/forward rules keep working.

It is opt-in (init only calls it when configured) and the caller treats any error as non-fatal.

func SetupNetworkInterfaces

func SetupNetworkInterfaces() error

func StartSSHServer

func StartSSHServer(ctx context.Context)

func StartServices

func StartServices(providers map[ServiceType][]*Service)

StartServices starts every service, gating each on its declared Needs and only marking a service's Provides available once it has started successfully.

func WaitForCarrier

func WaitForCarrier(ifname string, timeout time.Duration) bool

func WatchDevices

func WatchDevices(ctx context.Context) error

WatchDevices watches /sys for devices and populates /dev

func WithHostKeyFile

func WithHostKeyFile(fn string) option

Types

type Command

type Command string

func (Command) String

func (c Command) String() string

type Config

type Config struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewConfig

func NewConfig(filename string) *Config

func (*Config) Load

func (cfg *Config) Load() error

func (*Config) ReadInt

func (cfg *Config) ReadInt(k string, def int) (int, error)

func (*Config) ReadString

func (cfg *Config) ReadString(k string, def string) (string, error)

func (*Config) Save

func (cfg *Config) Save() error

func (*Config) WriteInt

func (cfg *Config) WriteInt(k string, val int)

func (*Config) WriteString

func (cfg *Config) WriteString(k string, val string)

type ControlRequest

type ControlRequest struct {
	Action  string `json:"action"`            // status | start | stop | restart
	Service string `json:"service,omitempty"` // empty with status = all services
}

ControlRequest is one command from `sv` to the supervisor.

type ControlResponse

type ControlResponse struct {
	OK       bool            `json:"ok"`
	Error    string          `json:"error,omitempty"`
	Services []ServiceStatus `json:"services,omitempty"`
}

ControlResponse is the supervisor's reply.

type MountOption

type MountOption struct {
	Source string
	Target string
	Type   string
	Flag   uintptr
	Option string
}

type Reaper

type Reaper = reaper.Reaper

func NewReaper

func NewReaper() *Reaper

type Service

type Service struct {
	Name          ServiceName
	Description   string // optional human-readable summary for `sv`
	Startup       Command
	Shutdown      Command
	Ready         Command // optional readiness probe for daemons
	User          string  // optional unprivileged user to run the service as
	Provides      []ServiceType
	Needs         []ServiceType
	Type          serviceType
	RestartPolicy restartPolicy
	// contains filtered or unexported fields
}

func ParseConfig

func ParseConfig(r io.Reader) (*Service, error)

Parses a single config file into the services it provides

func (*Service) Restart

func (s *Service) Restart() error

Restart stops the service (ignoring a "not running" error) and starts it again.

func (*Service) Start

func (s *Service) Start() error

Start runs the service. A one-shot service runs to completion; a daemon is launched and then kept alive in the background by supervise() per its restart policy. Either way Start returns once the service is up (so StartServices can release its dependents), not when a daemon eventually exits.

func (*Service) Stop

func (s *Service) Stop() error

type ServiceName

type ServiceName string

type ServiceStatus

type ServiceStatus struct {
	Name        string    `json:"name"`
	Description string    `json:"description,omitempty"`
	State       string    `json:"state"` // run | down | fail | starting | done
	PID         int       `json:"pid,omitempty"`
	Since       time.Time `json:"since"` // start of the current run (zero if not running)
	Restarts    int       `json:"restarts"`
	Enabled     bool      `json:"enabled"` // starts at boot
}

ServiceStatus is a point-in-time snapshot of a service, reported to `sv` over the control socket.

type ServiceType

type ServiceType string

type Supervisor

type Supervisor struct {
	// contains filtered or unexported fields
}

Supervisor owns the services parsed from /etc/rc.d and provides name-based control (start/stop/restart/status) on top of the dependency-ordered startup and per-service supervision in service.go. It backs the `sv` control socket.

func NewSupervisor

func NewSupervisor(providers map[ServiceType][]*Service) *Supervisor

NewSupervisor indexes the parsed providers map by service name.

func (*Supervisor) Disable

func (sup *Supervisor) Disable(name string) error

Disable marks a service not to start at boot (writing a disabled marker). It does not stop it now — use `sv stop` for that.

func (*Supervisor) Enable

func (sup *Supervisor) Enable(name string) error

Enable marks a service to start at boot (removing its disabled marker). It does not start it now.

func (*Supervisor) List

func (sup *Supervisor) List() []ServiceStatus

List returns every service's status, ordered by name.

func (*Supervisor) OnStart

func (sup *Supervisor) OnStart(fn func(name string, err error))

OnStart registers a callback invoked by StartAll for each service as it starts (or fails to). It must be set before StartAll and is used by PID 1 to print per-service boot progress.

func (*Supervisor) OnStop

func (sup *Supervisor) OnStop(fn func(name string, err error))

OnStop registers a callback invoked by StopAll for each running service as it stops. It must be set before StopAll and is the shutdown counterpart to OnStart, used by PID 1 to print per-service shutdown progress.

func (*Supervisor) Reload

func (sup *Supervisor) Reload(name string) error

Reload re-reads the service's unit file from /etc/rc.d and restarts it with the updated definition. The supervisor otherwise holds the definition parsed at boot, so a changed Startup command (or any other unit field) is not picked up by Restart alone; Reload makes live reconfiguration possible without a reboot. Dependency wiring (Needs/Provides) for the boot ordering is not recomputed — only this service's own definition is refreshed.

If the unit wasn't known at boot, Reload registers it as a brand-new service and starts it (see register), so dropping a new /etc/rc.d/<name> file and running `sv reload <name>` brings it up live.

func (*Supervisor) Restart

func (sup *Supervisor) Restart(name string) error

func (*Supervisor) Start

func (sup *Supervisor) Start(name string) error

func (*Supervisor) StartAll

func (sup *Supervisor) StartAll()

StartAll brings up every enabled service, honouring Needs/Provides ordering. Disabled services are excluded entirely (their capabilities aren't advertised, so a dependent of a disabled service won't start either); they can still be started by hand with `sv start`.

func (*Supervisor) Status

func (sup *Supervisor) Status(name string) (ServiceStatus, error)

func (*Supervisor) Stop

func (sup *Supervisor) Stop(name string) error

func (*Supervisor) StopAll

func (sup *Supervisor) StopAll()

StopAll stops every running daemon, reporting each via onStop. It's the shutdown counterpart to StartAll. The daemons have no stop-order dependencies among them, so they're stopped concurrently — shutdown waits roughly the slowest service's stop grace rather than the sum — and never longer than stopAllTimeout in all: a service still stopping then is reported as timed out and left behind. One-shot services have already run to completion, so there's nothing to stop.

type UI

type UI = ui.UI

func NewUI

func NewUI(w io.Writer) *UI

type Unmounter

type Unmounter func() error

func Mount

func Mount(mountOpts ...MountOption) (Unmounter, error)

Mount mounts list of mountOptions and returns a function to unmount them.

Directories

Path Synopsis
Package accounts is the system's account database — /etc/passwd, /etc/group and /etc/shadow — under the read-only root's rule that the image is the OS and what an operator adds is state (internal/persist).
Package accounts is the system's account database — /etc/passwd, /etc/group and /etc/shadow — under the read-only root's rule that the image is the OS and what an operator adds is state (internal/persist).
addgroup
Package addgroup creates a group, or adds a user to one, BusyBox-style.
Package addgroup creates a group, or adds a user to one, BusyBox-style.
adduser
Package adduser creates a user account, BusyBox-style.
Package adduser creates a user account, BusyBox-style.
arch
Package arch implements arch as GNU coreutils does: print the machine hardware name, as uname -m does.
Package arch implements arch as GNU coreutils does: print the machine hardware name, as uname -m does.
arp
Package arp is GoNIX's arp(8) for reading the neighbour table: the default listing, -a (BSD style), -n, -i IFACE and a host to look up, in net-tools' layout.
Package arp is GoNIX's arp(8) for reading the neighbour table: the default listing, -a (BSD style), -n, -i IFACE and a host to look up, in net-tools' layout.
bc
Package bc is an arbitrary-precision calculator: POSIX bc with the GNU extensions scripts use (&&, ||, !, print, # comments, multi-letter names, relational operators anywhere), and the -l math library.
Package bc is an arbitrary-precision calculator: POSIX bc with the GNU extensions scripts use (&&, ||, !, print, # comments, multi-letter names, relational operators anywhere), and the -l math library.
bootslot
Package bootslot is the `bootslot` applet: the command-line face of the A/B boot-slot state (internal/bootslot) for operators and the control plane.
Package bootslot is the `bootslot` applet: the command-line face of the A/B boot-slot state (internal/bootslot) for operators and the control plane.
cal
Package cal is the cal applet, laid out as util-linux 2.41's cal: a month (or three, or a year) with Sunday or Monday first, Julian day numbers with -j, and the British calendar's switch from Julian to Gregorian in September 1752 (2 September is followed by 14 September).
Package cal is the cal applet, laid out as util-linux 2.41's cal: a month (or three, or a year) with Sunday or Monday first, Julian day numbers with -j, and the British calendar's switch from Julian to Gregorian in September 1752 (2 September is followed by 14 September).
cat
chown
Package chown implements chown, and chgrp through Run.
Package chown implements chown, and chgrp through Run.
chroot
Package chroot implements chroot as GNU coreutils does: run a command with another root directory.
Package chroot implements chroot as GNU coreutils does: run a command with another root directory.
cloudinit
Package cloudinit is a minimal cloud-init for GoNIX: at boot it discovers the instance's SSH keys, hostname and user-data from the platform and applies them, so a fresh image becomes a configured server with no baked-in secrets.
Package cloudinit is a minimal cloud-init for GoNIX: at boot it discovers the instance's SSH keys, hostname and user-data from the platform and applies them, so a fresh image becomes a configured server with no baked-in secrets.
cmp
cp
cut
datadisk
Package datadisk mounts the optional persistent data disk as a supervised one-shot service (started from /etc/rc.d/datadisk, Provides: data).
Package datadisk mounts the optional persistent data disk as a supervised one-shot service (started from /etc/rc.d/datadisk, Provides: data).
dd
Package dd implements dd: copy a file block by block, converting as it goes.
Package dd implements dd: copy a file block by block, converting as it goes.
delgroup
Package delgroup removes a group the operator added, or a user from a group.
Package delgroup removes a group the operator added, or a user from a group.
deluser
Package deluser removes a user account the operator added.
Package deluser removes a user account the operator added.
df
dmesg
Package dmesg implements dmesg as util-linux does for the kernel ring buffer read through syslog(2): print it, filter it, clear it.
Package dmesg implements dmesg as util-linux does for the kernel ring buffer read through syslog(2): print it, filter it, clear it.
dos2unix
Package dos2unix is the dos2unix applet, and the shared conversion behind unix2dos.
Package dos2unix is the dos2unix applet, and the shared conversion behind unix2dos.
du
env
factor
Package factor is the factor applet: GNU factor's output, options and exit statuses, for numbers of any size (math/big; Pollard's rho with Miller-Rabin above trial division).
Package factor is the factor applet: GNU factor's output, options and exit statuses, for numbers of any size (math/big; Pollard's rho with Miller-Rabin above trial division).
file
Package file implements file: say what kind of data a file holds.
Package file implements file: say what kind of data a file holds.
find
Package find is the find applet: walk directory trees and evaluate an expression on every file.
Package find is the find applet: walk directory trees and evaluate an expression on every file.
free
Package free implements free as procps-ng 4 does: show the system's memory and swap use.
Package free implements free as procps-ng 4 does: show the system's memory and swap use.
gnutest
Package gnutest finds a GNU tool for the applet tests that compare their output with it.
Package gnutest finds a GNU tool for the applet tests that compare their output with it.
gonixinstall
Package gonixinstall is the `gonix-install` applet: it installs the running (live/ISO) GoNIX onto an internal disk in the A/B layout that internal/bootslot describes, so the machine then boots from the disk without the installation medium and can be updated slot-by-slot.
Package gonixinstall is the `gonix-install` applet: it installs the running (live/ISO) GoNIX onto an internal disk in the A/B layout that internal/bootslot describes, so the machine then boots from the disk without the installation medium and can be updated slot-by-slot.
groups
Package groups implements groups as GNU coreutils does: print the groups a user, or this process, is in.
Package groups implements groups as GNU coreutils does: print the groups a user, or this process, is in.
gunzip
Package gunzip is gzip -d, as GNU's gunzip is (see the gzip applet).
Package gunzip is gzip -d, as GNU's gunzip is (see the gzip applet).
gzip
Package gzip is the gzip applet, and the shared implementation behind gunzip (gzip -d) and zcat (gzip -dc), as GNU's gunzip and zcat are thin wrappers around gzip.
Package gzip is the gzip applet, and the shared implementation behind gunzip (gzip -d) and zcat (gzip -dc), as GNU's gunzip and zcat are thin wrappers around gzip.
halt
Package halt is halt, and the shared implementation of reboot and poweroff: by default each asks init to shut the system down (init's signals: SIGINT reboots, SIGUSR1 halts, SIGUSR2 powers off), with busybox's options.
Package halt is halt, and the shared implementation of reboot and poweroff: by default each asks init to shut the system down (init's signals: SIGINT reboots, SIGUSR1 halts, SIGUSR2 powers off), with busybox's options.
hostname
Package hostname implements hostname as the Linux hostname tool does: print or set the system's host name.
Package hostname implements hostname as the Linux hostname tool does: print or set the system's host name.
id
ip
Package ip is GoNIX's ip(8): show and change network interfaces, addresses, routes and neighbours, printing what iproute2 prints for the commands scripts use (ip addr / link / route / neigh, -4 -6, -o, -br, -j).
Package ip is GoNIX's ip(8): show and change network interfaces, addresses, routes and neighbours, printing what iproute2 prints for the commands scripts use (ip addr / link / route / neigh, -4 -6, -o, -br, -j).
kill
Package kill implements kill as procps-ng's /bin/kill does: send a signal to processes, or list and convert signal names.
Package kill implements kill as procps-ng's /bin/kill does: send a signal to processes, or list and convert signal names.
killall
Package killall implements killall as psmisc does: signal every process running a command by name.
Package killall implements killall as psmisc does: signal every process running a command by name.
link
Package link implements link as GNU coreutils does: make a hard link with link(2), nothing more.
Package link implements link as GNU coreutils does: make a hard link with link(2), nothing more.
ln
logname
Package logname implements logname as GNU coreutils does: print the name the session logged in as, which is not necessarily the current user.
Package logname implements logname as GNU coreutils does: print the name the session logged in as, which is not necessarily the current user.
ls
mknod
Package mknod implements mknod as GNU coreutils does: make block or character special files, or FIFOs.
Package mknod implements mknod as GNU coreutils does: make block or character special files, or FIFOs.
mv
netstat
Package netstat is GoNIX's netstat(8): sockets (-t -u -w, -l -a, -n, -p), the routing table (-r) and interface counters (-i), printed in net-tools' layout, read straight from /proc.
Package netstat is GoNIX's netstat(8): sockets (-t -u -w, -l -a, -n, -p), the routing table (-r) and interface counters (-i), printed in net-tools' layout, read straight from /proc.
network
Package network configures eth0 as a supervised service (started from /etc/rc.d/network): a static address when /etc/rc.conf sets IP, otherwise a DHCP client.
Package network configures eth0 as a supervised service (started from /etc/rc.d/network): a static address when /etc/rc.conf sets IP, otherwise a DHCP client.
nl
nohup
Package nohup implements nohup as GNU coreutils does: run a command that ignores hangups, with terminal input and output redirected, by replacing this process with it.
Package nohup implements nohup as GNU coreutils does: run a command that ignores hangups, with terminal input and output redirected, by replacing this process with it.
od
Package od implements od: dump files in octal, hexadecimal, decimal, floating point or character form.
Package od implements od: dump files in octal, hexadecimal, decimal, floating point or character form.
passwd
Package passwd changes, locks, unlocks or deletes a user's password, BusyBox-style.
Package passwd changes, locks, unlocks or deletes a user's password, BusyBox-style.
patch
Package patch is GNU patch's subset that scripts use: unified diffs (git's included) and context diffs, with offsets, fuzz, reversed-patch detection, rejects and backups, and GNU patch's messages and exit status.
Package patch is GNU patch's subset that scripts use: unified diffs (git's included) and context diffs, with offsets, fuzz, reversed-patch detection, rejects and backups, and GNU patch's messages and exit status.
pgrep
Package pgrep implements pgrep and pkill as procps-ng does: select processes by an extended regular expression and other criteria, then list (pgrep) or signal (pkill) them.
Package pgrep implements pgrep and pkill as procps-ng does: select processes by an extended regular expression and other criteria, then list (pgrep) or signal (pkill) them.
ping
Package ping is GoNIX's ping(8): ICMP echo, printing what iputils ping prints -- the PING header, one line per reply, and the statistics -- with its exit status (0 a reply came back, 1 none did, 2 an error).
Package ping is GoNIX's ping(8): ICMP echo, printing what iputils ping prints -- the PING header, one line per reply, and the statistics -- with its exit status (0 a reply came back, 1 none did, 2 an error).
poweroff
Package poweroff asks init to power off the system; see package halt for the options it shares with halt and the others.
Package poweroff asks init to power off the system; see package halt for the options it shares with halt and the others.
ps
Package ps implements ps as procps-ng does, for the options scripts use: UNIX (-e -f -o), BSD (aux) and GNU long (--pid --sort --no-headers) forms.
Package ps implements ps as procps-ng does, for the options scripts use: UNIX (-e -f -o), BSD (aux) and GNU long (--pid --sort --no-headers) forms.
pwd
Package pwd implements pwd as GNU coreutils does: print the working directory, physically (-P, the default) or as $PWD names it (-L).
Package pwd implements pwd as GNU coreutils does: print the working directory, physically (-P, the default) or as $PWD names it (-L).
reboot
Package reboot asks init to reboot the system; see package halt for the options it shares with halt and the others.
Package reboot asks init to reboot the system; see package halt for the options it shares with halt and the others.
rm
scp
Package scp is the remote end of OpenSSH's legacy SCP protocol: what an `scp -O` client runs on GoNIX as `scp -t TARGET` (receive) or `scp -f PATH...` (send).
Package scp is the remote end of OpenSSH's legacy SCP protocol: what an `scp -O` client runs on GoNIX as `scp -t TARGET` (receive) or `scp -f PATH...` (send).
sealctl
Package sealctl manages the disk key's seal (Home Cloud DESIGN §4.7):
Package sealctl manages the disk key's seal (Home Cloud DESIGN §4.7):
seq
setsid
Package setsid implements setsid as util-linux does: run a program in a new session.
Package setsid implements setsid as util-linux does: run a program in a new session.
sftpserver
Package sftpserver is the SFTP server a non-root SSH user's session runs: sshd starts it as `coreutils sftp-server` with the user's uid, gid and groups, in their home directory, and joins its stdin and stdout to the session channel.
Package sftpserver is the SFTP server a non-root SSH user's session runs: sshd starts it as `coreutils sftp-server` with the user's uid, gid and groups, in their home directory, and joins its stdin and stdout to the session channel.
sh
shuf
Package shuf is the shuf applet: GNU shuf's options, messages and exit statuses.
Package shuf is the shuf applet: GNU shuf's options, messages and exit statuses.
sshd
Package sshd runs the GoNIX SSH server as a standalone, supervised service (started from /etc/rc.d/sshd), rather than a goroutine inside init.
Package sshd runs the GoNIX SSH server as a standalone, supervised service (started from /etc/rc.d/sshd), rather than a goroutine inside init.
strace
go-strace only implements its syscall arg/ret decoding for amd64, so the real strace applet is amd64-only; strace_unsupported.go provides a stub elsewhere.
go-strace only implements its syscall arg/ret decoding for amd64, so the real strace applet is amd64-only; strace_unsupported.go provides a stub elsewhere.
sv
Package sv implements the `sv` service-control client: a thin front-end to the supervisor PID 1 runs, reached over the /run/sv.sock control socket.
Package sv implements the `sv` service-control client: a thin front-end to the supervisor PID 1 runs, reached over the /run/sv.sock control socket.
sync
Package sync is the sync applet, as GNU's: with no operand it flushes every filesystem; with files it syncs each one (-d: data only, -f: the filesystem holding it), reporting a file it cannot open and exiting 1.
Package sync is the sync applet, as GNU's: with no operand it flushes every filesystem; with files it syncs each one (-d: data only, -f: the filesystem holding it), reporting a file it cannot open and exiting 1.
tac
tar
Package tar is the tar applet: GNU tar's options, messages, listing format and exit statuses (0, or 2 after any error) for creating, listing and extracting archives, plain or compressed with gzip, bzip2, xz or zstd.
Package tar is the tar applet: GNU tar's options, messages, listing format and exit statuses (0, or 2 after any error) for creating, listing and extracting archives, plain or compressed with gzip, bzip2, xz or zstd.
tau
tee
tr
tty
Package tty implements tty as GNU coreutils does: print the name of the terminal on standard input.
Package tty implements tty as GNU coreutils does: print the name of the terminal on standard input.
unix2dos
Package unix2dos is the unix2dos applet: the dos2unix conversion run the other way (see the dos2unix applet).
Package unix2dos is the unix2dos applet: the dos2unix conversion run the other way (see the dos2unix applet).
unlink
Package unlink implements unlink as GNU coreutils does: remove one file with unlink(2), nothing more.
Package unlink implements unlink as GNU coreutils does: remove one file with unlink(2), nothing more.
unshare
Package unshare implements unshare as util-linux does: run a program in new namespaces.
Package unshare implements unshare as util-linux does: run a program in new namespaces.
wc
wg
Package wg is GoNIX's WireGuard control applet.
Package wg is GoNIX's WireGuard control applet.
wget
Package wget is the wget applet: GNU wget's options, file naming and exit statuses for fetching over HTTP and HTTPS.
Package wget is the wget applet: GNU wget's options, file naming and exit statuses for fetching over HTTP and HTTPS.
whoami
Package whoami implements whoami as GNU coreutils does: print the name of the effective user.
Package whoami implements whoami as GNU coreutils does: print the name of the effective user.
wol
Package wol is the `wol` applet: it arms (or disarms) Wake-on-LAN on a network interface, the same ETHTOOL_SWOL ioctl `ethtool -s IF wol g` performs.
Package wol is the `wol` applet: it arms (or disarms) Wake-on-LAN on a network interface, the same ETHTOOL_SWOL ioctl `ethtool -s IF wol g` performs.
yes
zcat
Package zcat is gzip -dc, as GNU's zcat is (see the gzip applet).
Package zcat is gzip -dc, as GNU's zcat is (see the gzip applet).
Package bootconfig parses the configuration a Library image takes at boot (docs/library-images.md, decisions 11–13): an env file of KEY=value lines.
Package bootconfig parses the configuration a Library image takes at boot (docs/library-images.md, decisions 11–13): an env file of KEY=value lines.
Package bootslot is the A/B boot-slot model for installed (on-disk) GoNIX: two OS slots, an EFI System Partition holding the loader and a GRUB environment block, and a small state machine over that block.
Package bootslot is the A/B boot-slot model for installed (on-disk) GoNIX: two OS slots, an EFI System Partition holding the loader and a GRUB environment block, and a small state machine over that block.
Package cefhost is the shared CEF (Chromium) offscreen-rendering host used by both browser host roles:
Package cefhost is the shared CEF (Chromium) offscreen-rendering host used by both browser host roles:
Package cefinput translates the browser shell's input into the CEF host's line protocol: keys (Linux evdev codes plus modifiers) into key and char commands carrying the Windows virtual-key code, the platform's native key code and the character the key produces, and wheel motion into CEF scroll deltas.
Package cefinput translates the browser shell's input into the CEF host's line protocol: keys (Linux evdev codes plus modifiers) into key and char commands carrying the Windows virtual-key code, the platform's native key code and the character the key produces, and wheel motion into CEF scroll deltas.
Package cefipc is the shared transport contract between the GoNIX/macOS browser shell and its CEF rendering host: a memory-mapped frame buffer plus the constants both sides agree on.
Package cefipc is the shared transport contract between the GoNIX/macOS browser shell and its CEF rendering host: a memory-mapped frame buffer plus the constants both sides agree on.
Package disksig recognises what a disk already holds, so that nothing in GoNIX formats a disk that is not blank.
Package disksig recognises what a disk already holds, so that nothing in GoNIX formats a disk that is not blank.
Package factoryreset carries out a household's request to erase its Home Cloud (DESIGN §4.4.1).
Package factoryreset carries out a household's request to erase its Home Cloud (DESIGN §4.4.1).
Package gui is a tiny, backend-agnostic windowing contract: a resizable software framebuffer (an *image.RGBA painted by the application) plus pointer, keyboard and scroll input and a run loop.
Package gui is a tiny, backend-agnostic windowing contract: a resizable software framebuffer (an *image.RGBA painted by the application) plus pointer, keyboard and scroll input and a run loop.
Package library builds and runs GoNIX Library images: a kernel, a slim init (cmd/libinit) and one or more Go programs, with no userland.
Package library builds and runs GoNIX Library images: a kernel, a slim init (cmd/libinit) and one or more Go programs, with no userland.
manifest
Package manifest is the contract between the two halves of a Library image (docs/library-images.md): `gonix pack` writes it into the initramfs, and cmd/libinit reads it at boot to learn what to run.
Package manifest is the contract between the two halves of a Library image (docs/library-images.md): `gonix pack` writes it into the initramfs, and cmd/libinit reads it at boot to learn what to run.
Package luks formats and opens LUKS2 volumes in pure Go (Home Cloud DESIGN §4.7: DATA and PERSIST are LUKS2, unlocked by init with a TPM-sealed key, recoverable with the household key).
Package luks formats and opens LUKS2 volumes in pure Go (Home Cloud DESIGN §4.7: DATA and PERSIST are LUKS2, unlocked by init with a TPM-sealed key, recoverable with the household key).
Package measure is the box's view of its own measured boot (Home Cloud DESIGN §4.7): it reads the TCG event log the firmware and the kernel's EFI stub leave behind, replays it into PCR values, predicts what those values will be after a staged update (the next kernel, the next command line) and turns expected PCR sets into the TPM policy digests the disk key is sealed under.
Package measure is the box's view of its own measured boot (Home Cloud DESIGN §4.7): it reads the TCG event log the firmware and the kernel's EFI stub leave behind, replays it into PCR values, predicts what those values will be after a staged update (the next kernel, the next command line) and turns expected PCR sets into the TPM policy digests the disk key is sealed under.
Package netconf brings network interfaces up: link state, DHCP and static addresses.
Package netconf brings network interfaces up: link state, DHCP and static addresses.
Package persist is the layout of an installed system's persist partition, and the rule that makes the OS read-only (Home Cloud DESIGN §4.2.1).
Package persist is the layout of an installed system's persist partition, and the rule that makes the OS read-only (Home Cloud DESIGN §4.2.1).
Package powerbutton reports presses of the machine's power button: the ACPI button on amd64, the GPIO power key on arm64.
Package powerbutton reports presses of the machine's power button: the ACPI button on amd64, the GPIO power key on arm64.
Package reaper makes PID 1 the single owner of child reaping.
Package reaper makes PID 1 the single owner of child reaping.
Package sealstate is the disk key's home on the ESP (Home Cloud DESIGN §4.7): the TPM-sealed passphrase that opens the LUKS2 keyslot init uses, and the boot policy it is sealed under.
Package sealstate is the disk key's home on the ESP (Home Cloud DESIGN §4.7): the TPM-sealed passphrase that opens the LUKS2 keyslot init uses, and the boot policy it is sealed under.
Package sshkeys manages root's authorized SSH keys and the gonix.sshkey= kernel command line option that supplies them.
Package sshkeys manages root's authorized SSH keys and the gonix.sshkey= kernel command line option that supplies them.
Package unlock opens the box's LUKS2 volumes at boot (Home Cloud DESIGN §4.7): the keyslot passphrase lives sealed on the ESP (sealstate); the TPM gives it back only to the measured boot it was sealed for, and dm-crypt mappings appear as /dev/mapper/<name>.
Package unlock opens the box's LUKS2 volumes at boot (Home Cloud DESIGN §4.7): the keyslot passphrase lives sealed on the ESP (sealstate); the TPM gives it back only to the measured boot it was sealed for, and dm-crypt mappings appear as /dev/mapper/<name>.
Package wlui is a minimal, pure-Go, software-rendered Wayland window toolkit.
Package wlui is a minimal, pure-Go, software-rendered Wayland window toolkit.
swizzle
Package swizzle provides functions for converting between RGBA pixel formats.
Package swizzle provides functions for converting between RGBA pixel formats.
text
Package text is a minimal pure-Go text-rendering layer for wlui apps.
Package text is a minimal pure-Go text-rendering layer for wlui apps.
ui
Package ui provides shared theming and drawing helpers for GoNIX GUI apps built on wlui — the small, home-grown beginnings of a widget layer.
Package ui provides shared theming and drawing helpers for GoNIX GUI apps built on wlui — the small, home-grown beginnings of a widget layer.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址