runit: poweroff/reboot scripts

This commit is contained in:
Cat /dev/Nulo 2022-11-17 22:28:32 -03:00
parent 88e9406963
commit 4622625570

View file

@ -362,6 +362,12 @@ if [ -z "$VIRTUALIZATION" ]; then
fi
]])
-- https://wiki.gentoo.org/wiki/Runit#Reboot_and_shutdown
add_executable("/usr/local/sbin/rpoweroff", [[#!/bin/sh
runit-init 0]])
add_executable("/usr/local/sbin/rreboot", [[#!/bin/sh
runit-init 6]])
add_packages({ "runit", "eudev" })
modules.runit.add_service("getty-tty1", [[#!/bin/sh
exec chpst -P getty 38400 tty1 linux]], false)