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:
@@ -66,7 +66,7 @@ def initDreplace():
|
||||
mw.execShell('chmod +x ' + file_bin)
|
||||
|
||||
aria2_path = '/root/.config/aria2'
|
||||
if not os.path.exists(initD_path):
|
||||
if not os.path.exists(aria2_path):
|
||||
mw.execShell('mkdir -p ' + aria2_path)
|
||||
mw.execShell('touch ' + aria2_path + '/aria2.session')
|
||||
|
||||
@@ -132,7 +132,7 @@ def getPathFile():
|
||||
user = mw.execShell(
|
||||
"who | sed -n '2, 1p' |awk '{print $1}'")[0].strip()
|
||||
return '/Users/' + user + '/.aria2/aria2.conf'
|
||||
return '/root/.aria2/aria2.conf'
|
||||
return '/root/.config/aria2/aria2.conf'
|
||||
|
||||
|
||||
def getInitDFile():
|
||||
@@ -175,7 +175,7 @@ def getLog():
|
||||
user = mw.execShell(
|
||||
"who | sed -n '2, 1p' |awk '{print $1}'")[0].strip()
|
||||
return '/Users/' + user + '/.aria2/aria2.log'
|
||||
return '/root/.aria2/aria2.log'
|
||||
return '/root/.config/aria2/aria2.log'
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
Reference in New Issue
Block a user