Crossfire Server, Branches 1.12  R18729
init.d File Reference

Go to the source code of this file.

Variables

stop start stop daemon stop
verbose exec 
$DAEMON
 
start start stop daemon start chuid games
 
 PATH
 
*echo Usage
 

Variable Documentation

stop start stop daemon stop verbose exec $DAEMON

Definition at line 41 of file init.d.

start start stop daemon start chuid games

Definition at line 38 of file init.d.

PATH
Initial value:
=/bin:/usr/bin:/sbin:/usr/sbin
DAEMON=/usr/games/crossfire
# The following value is extracted by debstd to figure out how to generate
# the postinst script. Edit the field to change the way the script is
# registered through update-rc.d (see the manpage for update-rc.d!)
FLAGS="defaults 50"
test -f $DAEMON || exit 0
umask 002
case "$1" in
restart|force-reload)
start-stop-daemon --stop --verbose --exec $DAEMON
echo -n "waiting a bit for the server to stop"
count=0
while test "`ps aux|grep /usr/games/crossfire|wc -l`" -gt 1
do
count=`expr $count + 1`
if [ $count -gt 30 ]
then
echo -n "crossfire not ready, not waiting any longer..."
break
fi
echo -n "."
done
echo
start-stop-daemon --start --chuid games:games --verbose --exec $DAEMON -- -detach
stop start stop daemon stop verbose exec $DAEMON
Definition: init.d:41
start start stop daemon start chuid games
Definition: init.d:38
#define sleep(x)
Definition: win32.h:167

Definition at line 9 of file init.d.

* echo Usage

Definition at line 44 of file init.d.