Compare commits

..

2 commits

Author SHA1 Message Date
271dc6fc6f runit: No intentar remontar el rootfs como read-only al apagar
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Es redundante :P
2022-06-17 23:25:56 -03:00
4353bfb6b9 runit: Matar servicios en vez de procesos al apagar
pkill parece estar roto, tomamos la recomendación de http://smarden.org/runit/debian/3
2022-06-17 23:25:45 -03:00

View file

@ -333,18 +333,10 @@ if [ -z "$VIRTUALIZATION" ]; then
udevadm control --exit
fi
msg "Sending TERM signal to processes..."
pkill --inverse -s0,1 -TERM
sleep 1
msg "Sending KILL signal to processes..."
pkill --inverse -s0,1 -KILL
if [ -z "$VIRTUALIZATION" ]; then
msg "Unmounting filesystems, disabling swap..."
swapoff -a
umount -r -a -t nosysfs,noproc,nodevtmpfs,notmpfs
msg "Remounting rootfs read-only..."
mount -o remount,ro /
fi
sync
@ -360,7 +352,7 @@ if [ -z "$VIRTUALIZATION" ]; then
fi
]])
add_packages({ "runit", "procps", "eudev" })
add_packages({ "runit", "eudev" })
modules.runit.add_service("getty-tty1", [[#!/bin/sh
exec chpst -P getty 38400 tty1 linux]])
modules.runit.add_service("getty-tty2", [[#!/bin/sh