This commit is contained in:
Mr Chen
2024-11-29 18:21:12 +08:00
parent d078b285a2
commit b350747eab
11 changed files with 11 additions and 16 deletions
-1
View File
@@ -167,7 +167,6 @@ def pSqliteDb(dbname='dnsapi'):
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
+1 -1
View File
@@ -115,7 +115,7 @@ def contentReplace(content):
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
+1 -1
View File
@@ -115,7 +115,7 @@ def contentReplace(content):
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
+1 -2
View File
@@ -147,7 +147,7 @@ def initJailD():
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
@@ -171,7 +171,6 @@ def initDreplace():
systemService = systemDir + '/' + getPluginName() + '.service'
if os.path.exists(systemDir) and not os.path.exists(systemService):
systemServiceTpl = getPluginDir() + '/init.d/' + getPluginName() + '.service.tpl'
service_path = mw.getServerDir()
content = mw.readFile(systemServiceTpl)
content = content.replace('{$SERVER_PATH}', service_path)
mw.writeFile(systemService, content)
+1 -1
View File
@@ -151,7 +151,7 @@ def contentReplace(content):
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
+1 -1
View File
@@ -118,7 +118,7 @@ def status():
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
+2 -3
View File
@@ -126,7 +126,7 @@ def status():
def contentReplace(content):
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
content = content.replace('{$SERVER_PATH}', service_path)
content = content.replace('{$PLUGIN_PATH}', getPluginDir())
@@ -166,7 +166,7 @@ def copyScripts():
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
@@ -202,7 +202,6 @@ def initDreplace():
systemService = systemDir + '/' + getPluginName() + '.service'
if os.path.exists(systemDir) and not os.path.exists(systemService):
systemServiceTpl = getPluginDir() + '/init.d/' + getPluginName() + '.service.tpl'
service_path = mw.getServerDir()
content = mw.readFile(systemServiceTpl)
content = contentReplace(content)
mw.writeFile(systemService, content)
+1 -1
View File
@@ -79,7 +79,7 @@ def status():
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
+1 -1
View File
@@ -88,7 +88,7 @@ def status():
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
+1 -2
View File
@@ -145,7 +145,7 @@ def contentReplace(content):
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
@@ -166,7 +166,6 @@ def initDreplace():
systemService = systemDir + '/' + getPluginName() + '.service'
if os.path.exists(systemDir) and not os.path.exists(systemService):
systemServiceTpl = getPluginDir() + '/init.d/' + getPluginName() + '.service.tpl'
service_path = mw.getServerDir()
content = mw.readFile(systemServiceTpl)
content = content.replace('{$SERVER_PATH}', service_path)
mw.writeFile(systemService, content)
+1 -2
View File
@@ -129,7 +129,7 @@ def mkdirAll():
def initDreplace():
file_tpl = getInitDTpl()
service_path = os.path.dirname(os.getcwd())
service_path = mw.getServerDir()
initD_path = getServerDir() + '/init.d'
if not os.path.exists(initD_path):
@@ -155,7 +155,6 @@ def initDreplace():
systemService = systemDir + '/sphinx.service'
systemServiceTpl = getPluginDir() + '/init.d/sphinx.service.tpl'
if os.path.exists(systemDir) and not os.path.exists(systemService):
service_path = mw.getServerDir()
se_content = mw.readFile(systemServiceTpl)
se_content = se_content.replace('{$SERVER_PATH}', service_path)
mw.writeFile(systemService, se_content)