Sha256: 0cfec3618f38867db3fc9e6692b57a26f9b9d3e127f206fa489bd2036eb0f9b2

Contents?: true

Size: 1.01 KB

Versions: 44

Compression:

Stored size: 1.01 KB

Contents

#!/bin/bash
#
# chkconfig: 35 90 12
# description: Spot instance watcher
#
# Get function from functions library
. /etc/init.d/functions
# Start the service spot-watcher
start() {
        initlog -c "echo -n Starting spot-watcher: "
        /bin/spot-watcher 2> /var/log/spot-watcher_error.log 1> var/log/spot-watcher.log &
        ### Create the lock file ###
        echo $! > /var/run/spot-watcher.pid
        touch /var/lock/subsys/spot-watcher
        success $"spot-watcher startup"
        echo
}
# Restart the service spot-watcher
stop() {
        initlog -c "echo -n Stopping spot-watcher: "
        killproc spot-watcher
        ### Now, delete the lock file ###
        rm -f /var/lock/subsys/spot-watcher
        echo
}
### main logic ###
case "$1" in
  start)
        start
        ;;
  stop)
        stop
        ;;
  status)
        status spot-watcher
        ;;
  restart|reload|condrestart)
        stop
        start
        ;;
  *)
        echo $"Usage: $0 {start|stop|restart|reload|status}"
        exit 1
esac
exit 0

Version data entries

44 entries across 44 versions & 1 rubygems

Version Path
sumomo-0.8.7 data/sumomo/sources/spot-watcher.sh
sumomo-0.8.6 data/sumomo/sources/spot-watcher.sh
sumomo-0.8.4 data/sumomo/sources/spot-watcher.sh
sumomo-0.8.3 data/sumomo/sources/spot-watcher.sh
sumomo-0.8.2 data/sumomo/sources/spot-watcher.sh
sumomo-0.8.1 data/sumomo/sources/spot-watcher.sh
sumomo-0.8.0 data/sumomo/sources/spot-watcher.sh
sumomo-0.7.3 data/sumomo/sources/spot-watcher.sh
sumomo-0.7.2 data/sumomo/sources/spot-watcher.sh
sumomo-0.7.1 data/sumomo/sources/spot-watcher.sh
sumomo-0.6.4 data/sumomo/sources/spot-watcher.sh
sumomo-0.6.3 data/sumomo/sources/spot-watcher.sh
sumomo-0.6.2 data/sumomo/sources/spot-watcher.sh
sumomo-0.6.1 data/sumomo/sources/spot-watcher.sh
sumomo-0.6.0 data/sumomo/sources/spot-watcher.sh
sumomo-0.5.2 data/sumomo/sources/spot-watcher.sh
sumomo-0.5.1 data/sumomo/sources/spot-watcher.sh
sumomo-0.5.0 data/sumomo/sources/spot-watcher.sh
sumomo-0.4.0 data/sumomo/sources/spot-watcher.sh
sumomo-0.3.0 data/sumomo/sources/spot-watcher.sh