aboutsummaryrefslogtreecommitdiffstats
path: root/bootscripts/contrib/lsb-v3/init.d/template
diff options
context:
space:
mode:
authorDJ Lucas <dj@linuxfromscratch.org>2011-05-14 19:41:18 +0000
committerDJ Lucas <dj@linuxfromscratch.org>2011-05-14 19:41:18 +0000
commitcb95d5f23b3c5b803f83a38f09d654bd9924f421 (patch)
treeabd65023fedb4c995ad741b53c3b1606faba46a0 /bootscripts/contrib/lsb-v3/init.d/template
parent03bf43c6eab6a31a2e43aa1bd48ff375f5e04173 (diff)
Changed distribution directory structure.
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@9530 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
Diffstat (limited to 'bootscripts/contrib/lsb-v3/init.d/template')
-rw-r--r--bootscripts/contrib/lsb-v3/init.d/template90
1 files changed, 0 insertions, 90 deletions
diff --git a/bootscripts/contrib/lsb-v3/init.d/template b/bootscripts/contrib/lsb-v3/init.d/template
deleted file mode 100644
index cb3222a35..000000000
--- a/bootscripts/contrib/lsb-v3/init.d/template
+++ /dev/null
@@ -1,90 +0,0 @@
-#!/bin/sh
-# Begin /etc/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/sysconfig/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 /etc/init.d/template