3 # Provides: tango-starter
4 # Required-Start: $syslog
5 # Required-Stop: $syslog
6 # Should-Start: $local_fs
7 # Should-Stop: $local_fs
8 # Default-Start: 2 3 4 5
10 # Short-Description: Start the Advanced Configuration and Power Interface daemon
11 # Description: Provide a socket for X11, hald and others to multiplex
15 PATH
=/usr
/local
/sbin
:/usr
/local
/bin
:/sbin
:/bin
:/usr
/sbin
:/usr
/bin
16 DAEMON
="/usr/lib/tango/Starter"
17 DAEMON_OPTS
=" 1 -ORBendPoint giop:tcp::10000"
21 test -x $DAEMON ||
exit 0
23 # Include tango defaults if available
24 if [ -f /etc
/default
/tango
] ; then
32 echo -n "Starting $DESC: "
33 start-stop-daemon
--start --quiet --chuid tango
:tango
--background --make-pidfile --pidfile /var
/run
/$NAME.pid \
34 --exec $DAEMON -- $DAEMON_OPTS
38 echo -n "Stopping $DESC: "
39 start-stop-daemon
--stop --quiet --chuid tango
:tango
--pidfile /var
/run
/$NAME.pid \
40 --exec $DAEMON --oknodo
45 # If the daemon can reload its config files on the fly
46 # for example by sending it SIGHUP, do it here.
48 # If the daemon responds to changes in its config file
49 # directly anyway, make this a do-nothing entry.
51 # echo "Reloading $DESC configuration files."
52 # start-stop-daemon --stop --signal 1 --quiet --pidfile \
53 # /var/run/$NAME.pid --exec $DAEMON
57 # If the "reload" option is implemented, move the "force-reload"
58 # option to the "reload" entry above. If not, "force-reload" is
59 # just the same as "restart" except that it does nothing if the
60 # daemon isn't already running.
61 # check wether $DAEMON is running. If so, restart
62 start-stop-daemon
--stop --test --quiet --pidfile \
63 /var
/run
/$NAME.pid
--exec $DAEMON \
68 echo -n "Restarting $DESC: "
69 start-stop-daemon
--stop --quiet --pidfile \
70 /var
/run
/$NAME.pid
--exec $DAEMON
72 start-stop-daemon
--start --quiet --make-pidfile --background --pidfile \
73 /var
/run
/$NAME.pid
--exec $DAEMON -- $DAEMON_OPTS
78 # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2
79 echo "Usage: $N {start|stop|restart|force-reload}" >&2