nixpkgs/test/upstart-jobs/halt.nix
Eelco Dolstra 49b2a218b5 * Support entering maintenance mode ("shutdown now") and powering off
the system ("halt").

svn path=/nixu/trunk/; revision=7083
2006-11-20 20:50:52 +00:00

24 lines
323 B
Nix

{bash}:
{
name = "sys-halt";
job = "
start on reboot
start on halt
start on system-halt
start on power-off
script
exec < /dev/tty1 > /dev/tty1 2>&1
echo \"\"
echo \"<<< SYSTEM SHUTDOWN >>>\"
echo \"\"
# Right now all events above power off the system.
exec halt -f -p
end script
";
}