add correct runlevel actions to monitor-runlevelagent.ini
[monitor.git] / monitor-runlevelagent.init
1 #!/bin/bash
2 #
3 # monitor-runlevelagent starts the RunlevelAgent in production mode.
4 #
5 # Load before nm, vcached, and vservers, vserver-reference
6 # chkconfig: 3 14 85
7 # description: Start RunlevelAgent to report the current Runlevel to PLC at
8 #               periodic intervals.
9 #
10 # Stephen Soltesz <soltesz@cs.princeton.edu>
11 # Copyright (C) 2008 The Trustees of Princeton University
12 #
13 # $Id$
14 #
15
16 case "$1" in
17     start|restart|reload)
18
19                 start_rla
20
21         ;;
22     stop|status)
23         exit 0
24         ;;
25     *)
26         echo $"Usage: $0 {start|stop|restart|status}"
27         exit 1
28         ;;
29 esac
30
31 function start_rla ()
32 {
33         RLA=/usr/bin/RunlevelAgent.py
34         $RLA &> /var/log/rla.log &
35 }