runit

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

commit fa9ae8fcca4d354e533b8f7aebd6d3a663a834e5
parent 4e5ecbeb5889e08e5e7a76f90792df8be454273d
Author: Gerrit Pape <pape@smarden.org>
Date:   Thu, 26 Sep 2002 11:19:08 +0000

adapt stage 3.

Diffstat:
Metc/debian/3 | 17+++++------------
Metc/freebsd/3 | 23+++++++++--------------
Metc/openbsd/3 | 26++++++++------------------
3 files changed, 22 insertions(+), 44 deletions(-)

diff --git a/etc/debian/3 b/etc/debian/3 @@ -1,21 +1,14 @@ #!/bin/sh +exec 2>&1 LAST=0 test -r /etc/runit/reboot && LAST=6 -echo 'Stopping getties...' -/command/svc -d /service/getty-* -/command/svwaitdown -t14 /service/getty-* || \ - ( echo 'Killing getties...' ; /command/svc -k /service/getty-* ) +echo 'Waiting for getties to stop...' +/command/svwaitdown -xk -t14 /service/getty-* -echo 'Stopping services...' -/command/svc -d /service/* -/command/svwaitdown -t350 /service/* || \ - ( echo 'Killing services...' ; /command/svc -k /service/* ) - -echo 'Stopping log services...' -/command/svc -d /service/*/log -/command/svwaitdown -t35 /service/*/log +echo 'Waiting for services to stop...' +/command/svwaitdown -xk -t350 /service/* echo 'Shutdown...' /etc/init.d/rc $LAST diff --git a/etc/freebsd/3 b/etc/freebsd/3 @@ -1,21 +1,16 @@ #!/bin/sh -PATH=/bin:/sbin:/command +exec 2>&1 -echo 'Stopping services...' -svc -d /service/* -svwaitdown -t350 /service/* || ( echo 'Killing services...' ; \ - svc -k /service/* ; svwaitdown /service/* ) +LAST=0 +test -r /etc/runit/reboot && LAST=6 -echo 'Stopping log services...' -svc -d /service/*/log -svwaitdown -t35 /service/*/log || ( echo 'Killing log services...' ; \ - svc -k /service/*/log ; svwaitdown /service/*/log ) +echo 'Waiting for getties to stop...' +/command/svwaitdown -xk -t14 /service/getty-* + +echo 'Waiting for services to stop...' +/command/svwaitdown -xk -t350 /service/* echo 'Shutdown...' -if test -r /etc/runit/reboot; then - exec reboot -else - exec halt -fi +/etc/init.d/rc $LAST exit 0 diff --git a/etc/openbsd/3 b/etc/openbsd/3 @@ -1,26 +1,16 @@ #!/bin/sh -PATH=/bin:/sbin:/command +exec 2>&1 -echo 'Stopping getties...' -svc -d /service/getty-* -svwaitdown -t14 /service/getty-* || ( echo 'Killing getties...' ; \ - svc -k /service/getty-* ; svwaitdown /service/getty-* ) +LAST=0 +test -r /etc/runit/reboot && LAST=6 -echo 'Stopping services...' -svc -d /service/* -svwaitdown -t350 /service/* || ( echo 'Killing services...' ; \ - svc -k /service/* ; svwaitdown /service/* ) +echo 'Waiting for getties to stop...' +/command/svwaitdown -xk -t14 /service/getty-* -echo 'Stopping log services...' -svc -d /service/*/log -svwaitdown -t35 /service/*/log || ( echo 'Killing log services...' ; \ - svc -k /service/*/log ; svwaitdown /service/*/log ) +echo 'Waiting for services to stop...' +/command/svwaitdown -xk -t350 /service/* echo 'Shutdown...' -if test -r /etc/runit/reboot; then - exec reboot -else - exec halt -fi +/etc/init.d/rc $LAST exit 0