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: starts MRIMt transport for Jabber
11 # Description: starts MRIMt which provides a gateway that allows Jabber users to communicate with their
12 # contacts on the ICQ Messenger network. It can connect to any Jabber server
13 # that supports the Connect component mechanism.
17 export PATH
=/sbin
:/bin
:/usr
/sbin
:/usr
/bin
20 DESC
="Mail.ru Agent transport for Jabber"
23 PIDFILE
=$PIDDIR/$NAME.pid
27 SSD_OPTS
="--pidfile=$PIDFILE --name=python --user=$USER"
29 DAEMON
=/usr
/bin
/python
30 OPTIONS
="/usr/lib/mrimt/src/mrim.py -d -c /etc/ejabberd/mrimt.conf -p $PIDFILE"
32 test -f $DAEMON ||
exit 0
34 if test ! -e $PIDDIR; then
36 chown
$USER:$GROUP $PIDDIR
41 echo -n "Starting $DESC: "
42 # (start-stop-daemon --start $SSD_OPTS --startas "$DAEMON" --chuid "$USER" -- $OPTIONS)
43 # if test "$?" = 0; then echo "$NAME."; fi
44 su
$USER -c "$DAEMON $OPTIONS"
47 echo -n "Stopping $DESC: "
48 # (start-stop-daemon --stop $SSD_OPTS --retry 10)
49 # if test "$?" = 0; then echo "$NAME."; fi
53 echo -n "Reloading $DESC configuration..."
54 (start-stop-daemon
--stop $SSD_OPTS --signal HUP
)
55 if test "$?" = 0; then echo 'done.'; fi
62 echo "Usage: /etc/init.d/$NAME {start|stop|restart|reload|force-reload}" >&2