2015-12-07 22:11:31 +08:00
|
|
|
description "Monkey Island Service"
|
|
|
|
|
|
|
|
start on runlevel [2345]
|
|
|
|
stop on runlevel [!2345]
|
|
|
|
|
|
|
|
respawn
|
|
|
|
respawn limit unlimited
|
|
|
|
|
|
|
|
script
|
|
|
|
chdir /var/monkey_island/cc
|
|
|
|
exec python main.py
|
|
|
|
end script
|
|
|
|
|
|
|
|
post-stop script
|
|
|
|
if [ -n $UPSTART_EVENTS ]; then
|
2015-12-07 22:25:09 +08:00
|
|
|
exec sleep 2
|
2015-12-07 22:11:31 +08:00
|
|
|
fi
|
|
|
|
end script
|