diff options
Diffstat (limited to 'lsb-bootscripts/etc/init.d/template')
-rw-r--r-- | lsb-bootscripts/etc/init.d/template | 90 |
1 files changed, 0 insertions, 90 deletions
diff --git a/lsb-bootscripts/etc/init.d/template b/lsb-bootscripts/etc/init.d/template deleted file mode 100644 index 4d4cf8c7b..000000000 --- a/lsb-bootscripts/etc/init.d/template +++ /dev/null @@ -1,90 +0,0 @@ -#!/bin/sh -# Begin $RC_BASE/init.d/template - -### BEGIN INIT INFO -# Provides: template -# Required-Start: -# Should-Start: -# Required-Stop: -# Should-Stop: -# Default-Start: -# Default-Stop: -# Short-Description: -# Description: -# X-LFS-Provided-By: -### END INIT INFO - -# Source the LSB init-functions, ours are pulled in from there. -. /lib/lsb/init-functions - -# These are optional, but required for chk_stat. They will be used in -# the rest of the functions if defined, else you must provide a program -# name to control, and a message ('Starting Template Service...' -# or 'Stoping Template Service...') to evauate_retval. See the -# documentaion in the lfs-fucntions file for more information. -MESSAGE="Template Service" -BIN_FILE="/some/path/to/template" -CONFIGFILE="/etc/default/template.conf" - -# check that $BIN_FILE exists and is executable, and $CONFIGFILE exists. -chk_stat - -# LSB Defined functions require that at least $BIN_FILE be passed to them, -# where as lfs-functions will use the $BIN_FILE environment variable. -# loadproc() and endproc() are just wrappers that pass everything on to -# the LSB defined functions. - -case "${1}" in - start) - #start_daemon "${BIN_FILE}" -arg1 -arg2 #... or: - loadproc -arg1 -arg2 -arg3 #... - evaluate_retval start - ;; - - stop) - #killproc -TERM "${BIN_FILE}" or: - endproc - evaluate_retval stop - ;; - - force-reload) - reloadproc -force - evaluate_retval force-reload - ;; - - restart) - $0 stop - $0 start - ;; - - status) - statusproc - ;; - -# reload and try-restart are optional per LSB requirements - reload) - reloadproc - evaluate_retval reload - ;; - - try-restart) - # Since this is optional there is no lfs-function for this one... - # might be at a later time if used enough, but I doubt it usefullness. - pidofproc "${BIN_FILE}" > /dev/null - if [ "${?}" -ne "0" ]; then - MESSAGE="${MESSAGE}: Not Running" - else - $0 stop - $0 start - exit 0 - fi - evaluate_retval try-restart - ;; - - *) - echo "Usage: ${0} {start|stop|{force-}reload|{try-}restart|status}" - exit 1 - ;; -esac - -# End $RC_BASE/init.d/template |