aboutsummaryrefslogtreecommitdiffstats
system-init

goetia-linux-init
goetia
Software
0x53.net

The system-init program

system-init is a minimal, scripted init to bring up a goetia based system.

Interface

     system-init
  • system-init takes no arguments.
  • It makes /dev/console its stdout and stderr.
  • It reads the environment variable BUNDLE, which can be specified on the Kernel command line. If it is undefined, it uses default as the value.
  • It reads the environment variable PATH, which can be specified on the Kernel command line. If it is undefined, it uses /command:/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/libexec:/usr/local/libexec as the value.
  • It sets the PATH environment variable to the value chosen above.
  • It chdirs to /.
  • It runs s6-setsid to become the session leader.
  • It creates the runtime directory if it does not already exist.
  • It mounts the runtime directory tmpfs.
  • It copies the old system logs from the uncaught-logs/ subdirectory of the system log directory to the log/ subdirectory of the system runtime directory if they exist.
  • It runs prepare-svscan with the proper arguments.
  • Finally, it executes into s6-svscan on the scandir represented by the service/ subdirectory of the system runtime directory.

Exit codes

  • system-init usually executes into s6-svscan which exits according to its page.
  • Since system-init is an execline script, it exits with an approximation of employed program that failed.
  • system-init mostly uses execline and s6 software, the exit behaviour of which can be looked up on their respective pages.
  • See also: execline exit code handling.

Options

  • There are no options to system-init.

Notes

system-init is primarily intended to be used as an init for an acutal boot process, not for containers.