mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
Update index.py
This commit is contained in:
@@ -102,6 +102,10 @@ def initDreplace():
|
|||||||
public.writeFile(file_py, content)
|
public.writeFile(file_py, content)
|
||||||
public.execShell('chmod +x ' + file_py)
|
public.execShell('chmod +x ' + file_py)
|
||||||
|
|
||||||
|
log_file = getLog()
|
||||||
|
if os.path.exists(log_file):
|
||||||
|
public.writeFile(log_file, '')
|
||||||
|
|
||||||
return file_bin
|
return file_bin
|
||||||
|
|
||||||
|
|
||||||
@@ -116,6 +120,7 @@ def runShell(shell):
|
|||||||
def start():
|
def start():
|
||||||
file = initDreplace()
|
file = initDreplace()
|
||||||
data = runShell(file + ' start')
|
data = runShell(file + ' start')
|
||||||
|
|
||||||
if data[1] == '':
|
if data[1] == '':
|
||||||
return 'ok'
|
return 'ok'
|
||||||
return 'fail'
|
return 'fail'
|
||||||
|
|||||||
Reference in New Issue
Block a user