mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-10 04:59:25 +08:00
update
This commit is contained in:
@@ -135,7 +135,7 @@ def start():
|
||||
# print data
|
||||
if data[1] == '':
|
||||
return 'ok'
|
||||
return data[1]
|
||||
return data[0]
|
||||
|
||||
|
||||
def stop():
|
||||
@@ -143,7 +143,7 @@ def stop():
|
||||
data = public.execShell(file + ' stop')
|
||||
if data[1] == '':
|
||||
return 'ok'
|
||||
return 'fail'
|
||||
return data[1]
|
||||
|
||||
|
||||
def restart():
|
||||
@@ -151,7 +151,7 @@ def restart():
|
||||
data = public.execShell(file + ' reload')
|
||||
if data[1] == '':
|
||||
return 'ok'
|
||||
return 'fail'
|
||||
return data[1]
|
||||
|
||||
|
||||
def reload():
|
||||
@@ -159,7 +159,7 @@ def reload():
|
||||
data = public.execShell(file + ' reload')
|
||||
if data[1] == '':
|
||||
return 'ok'
|
||||
return 'fail'
|
||||
return data[1]
|
||||
|
||||
|
||||
def initdStatus():
|
||||
|
||||
@@ -65,7 +65,12 @@ start() {
|
||||
stop() {
|
||||
cd ${GOGS_HOME}
|
||||
echo "Shutting down ${SERVICENAME}: \c"
|
||||
pkill ${NAME}
|
||||
which "killproc" > /dev/null
|
||||
if [ $? -eq 0 ];then
|
||||
killproc ${NAME}
|
||||
else
|
||||
pkill ${NAME}
|
||||
fi
|
||||
RETVAL=$?
|
||||
[ $RETVAL = 0 ] && rm -f ${LOCKFILE} && echo "\033[32mdone\033[0m"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user