rc: improve print of syshook invokes

This commit is contained in:
Franco Fichtner 2017-05-15 06:37:11 +02:00
parent 24403a5122
commit 355939b228
5 changed files with 8 additions and 3 deletions

View File

@ -1,6 +1,6 @@
#!/bin/sh
# Copyright (c) 2015-2016 Franco Fichtner <franco@opnsense.org>
# Copyright (c) 2015-2017 Franco Fichtner <franco@opnsense.org>
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
@ -54,11 +54,12 @@ for SYSHOOK in ${SYSHOOKS}; do
# extract syshook origin
SYSHOOK=${SYSHOOK##"${SYSDIR}/"}
SYSHOOK=${SYSHOOK%%".${SYSLEVEL}"}
SYSNAME=${SYSHOOK#??-}
echo "rc.syshook(${SYSLEVEL}): running ${SYSHOOK#??-}"
echo ">>> Invoking ${SYSLEVEL} script '${SYSNAME}'"
if ! ${SYSDIR}/${SYSHOOK}.${SYSLEVEL}; then
echo "rc.syshook(${SYSLEVEL}): error in ${SYSHOOK#??-}"
echo ">>> Error in ${SYSLEVEL} script '${SYSNAME}'"
fi
done

View File

@ -1,2 +1,3 @@
#!/bin/sh
/usr/local/sbin/beep.sh stop

View File

@ -1,2 +1,3 @@
#!/bin/sh
/usr/local/etc/rc.freebsd start

View File

@ -1,3 +1,4 @@
#!/bin/sh
echo -n "Starting Cron: "
configctl cron restart

View File

@ -1,2 +1,3 @@
#!/bin/sh
/usr/local/sbin/beep.sh start