Last active
August 29, 2015 14:05
-
-
Save hnq90/171b9f2188033eee5b60 to your computer and use it in GitHub Desktop.
Startup script for the Parry Server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# parry-server Startup script for the Parry Server | |
# | |
# chkconfig: - 85 15 | |
# description: PARRY Server Service | |
# author: HuyNQ <[email protected]> | |
# processname: parry-server | |
# | |
PARRY_HOME="parry-directory" | |
setup() { | |
cd $PARRY_HOME | |
./bin/parry setup | |
} | |
start(){ | |
cd $PARRY_HOME | |
./bin/parry start | |
} | |
stop(){ | |
cd $PARRY_HOME | |
./bin/parry stop | |
} | |
restart(){ | |
cd $PARRY_HOME | |
./bin/parry restart | |
} | |
reset(){ | |
cd $PARRY_HOME | |
./bin/parry reset | |
} | |
case "$1" in | |
setup) | |
setup | |
;; | |
start) | |
start | |
;; | |
stop) | |
stop | |
;; | |
restart) | |
restart | |
;; | |
reset) | |
reset | |
;; | |
*) | |
echo "Usage: parry-server {setup|start|stop|restart}" | |
exit 1 | |
esac | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment