Change the folder structure.

This commit is contained in:
Zic
2017-12-23 23:12:03 +08:00
parent deaeb39618
commit 1f01b89c4c
6 changed files with 32 additions and 49 deletions

14
build/service/shutdown.sh Normal file
View File

@ -0,0 +1,14 @@
#!/bin/bash
DIR="$( cd "$( dirname "$0" )" && pwd )"
EXE_PATH=$DIR/tank
EDASPID=`ps -ef | grep "$EXE_PATH"|grep -v grep |head -n 1 | awk '{print $2}'`
if [ -z $EDASPID ];
then
echo "Cannot find $EXE_PATH."
else
kill -9 $EDASPID
echo $EXE_PATH
echo 'Shutdown successfully.'
fi

12
build/service/startup.sh Normal file
View File

@ -0,0 +1,12 @@
#!/bin/bash
# executable path
DIR="$( cd "$( dirname "$0" )" && pwd )"
EXE_PATH=$DIR/tank
if [ -f "$EXE_PATH" ]; then
nohup $EXE_PATH >/dev/null 2>&1 &
else
echo 'Cannot find $EXE_PATH.'
exit 1
fi