X-Git-Url: https://git.grml.org/?p=grml-autoconfig.git;a=blobdiff_plain;f=debian%2Fpostinst;h=3783fbeaa024f34577d5b2f435ecce28bfd7de35;hp=2e94284a3af24b5b5d117122c09974ed015c3d6b;hb=bc6656c8a62d5b89aad347ebed4c81cc14e8cbdd;hpb=efd6786e49003dac27e4ff9f038a1e134ce43cca diff --git a/debian/postinst b/debian/postinst index 2e94284..3783fbe 100755 --- a/debian/postinst +++ b/debian/postinst @@ -6,9 +6,11 @@ if [ "$1" = "configure" ]; then # begin of "create special init scripts which won't be touched any more by grml" . /etc/grml/lsb-functions +DATE=$(date) + +# bootup INITSCRIPT=bootlocal INITNAME=/etc/init.d/${INITSCRIPT} -DATE=$(date) for initscript in ${INITNAME}.first ${INITNAME}.middle ${INITNAME}.last ; do if ! [ -r "$initscript" ] ; then @@ -34,8 +36,39 @@ done update-rc.d ${INITSCRIPT}.first start 1 S . >/dev/null update-rc.d ${INITSCRIPT}.middle start 29 2 . >/dev/null update-rc.d ${INITSCRIPT}.last start 99 2 . >/dev/null -# end of "create special init scripts which won't be touched any more by grml" +# shutdown +INITSCRIPT=haltlocal +INITNAME=/etc/init.d/${INITSCRIPT} + +for initscript in ${INITNAME}.first ${INITNAME}.middle ${INITNAME}.last ; do + if ! [ -r "$initscript" ] ; then + einfo "Creating ${initscript}" + cat >$initscript </dev/null +update-rc.d ${INITSCRIPT}.middle stop 29 0 1 6 . >/dev/null +update-rc.d ${INITSCRIPT}.last stop 99 0 1 6 . >/dev/null + +# end of "create special init scripts which won't be touched any more by grml" fi +#DEBHELPER# + exit 0