add start and stop checks
This commit is contained in:
parent
e27fbb5bad
commit
4b85f9c9fd
|
@ -1,18 +1,19 @@
|
|||
#!/bin/sh
|
||||
# read our configuration
|
||||
source /boot/config/plugins/ipmitool-plugin/ipmitool-plugin.cfg
|
||||
|
||||
prog="ipmievd"
|
||||
prog2="ipmitail"
|
||||
IPMIEVD="/usr/sbin/$prog"
|
||||
IPMITAIL="/usr/local/emhttp/plugins/ipmitool-plugin/scripts/$prog2"
|
||||
LOCKFILE="/var/lock/$prog"
|
||||
PIDFILE="/var/run/$prog.pid0"
|
||||
CONFIG="/boot/config/plugins/ipmitool-plugin"
|
||||
CONFIG="/boot/config/plugins/ipmitool-plugin/ipmitool-plugin.cfg"
|
||||
OPTIONS=""
|
||||
|
||||
# no-op if already running
|
||||
if [ ! -r $PIDFILE ]; then
|
||||
if [ -e $CONFIG ]; then
|
||||
source $CONFIG
|
||||
if [ $SERVICE == "enable" ]; then
|
||||
# no-op if already running
|
||||
if [ ! -r $PIDFILE ]; then
|
||||
if [ $REMOTE == "enable" ]; then
|
||||
OPTIONS="-I lanplus -H $IPADDR -U $USER -P $(echo $PASSWORD | base64 --decode)"
|
||||
fi
|
||||
|
@ -32,4 +33,6 @@ if [ ! -r $PIDFILE ]; then
|
|||
if [ -r $PIDFILE ]; then
|
||||
nohup $IPMITAIL >/dev/null 2>&1 < /dev/null &
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
|
@ -1,7 +1,4 @@
|
|||
#!/bin/sh
|
||||
# read our configuration
|
||||
source /boot/config/plugins/ipmitool-plugin/ipmitool-plugin.cfg
|
||||
|
||||
prog="ipmievd"
|
||||
prog2="ipmitail"
|
||||
LOCKFILE="/var/lock/$prog"
|
||||
|
|
Loading…
Reference in New Issue
Block a user