fix
This commit is contained in:
parent
f43ae1a877
commit
698c684a8a
|
|
@ -616,7 +616,7 @@ class system_api:
|
|||
def getServerInfo(self):
|
||||
import urllib.request
|
||||
import ssl
|
||||
upAddr = 'https://raw.githubusercontent.com/midoks/mdserver-web/master/version/info.json'
|
||||
upAddr = 'https://cdn.jsdelivr.net/gh/midoks/mdserver-web@latest/version/info.json'
|
||||
try:
|
||||
context = ssl._create_unverified_context()
|
||||
req = urllib.request.urlopen(upAddr, context=context, timeout=3)
|
||||
|
|
|
|||
|
|
@ -32,6 +32,11 @@ def getInitDFile():
|
|||
|
||||
|
||||
def getConf():
|
||||
path = getServerDir() + "/redis.conf"
|
||||
return path
|
||||
|
||||
|
||||
def getConfTpl():
|
||||
path = getPluginDir() + "/config/redis.conf"
|
||||
return path
|
||||
|
||||
|
|
@ -84,7 +89,7 @@ def initDreplace():
|
|||
mw.execShell('chmod +x ' + file_bin)
|
||||
|
||||
# config replace
|
||||
conf_content = mw.readFile(getConf())
|
||||
conf_content = mw.readFile(getConfTpl())
|
||||
conf_content = conf_content.replace('{$SERVER_PATH}', service_path)
|
||||
mw.writeFile(getServerDir() + '/redis.conf', conf_content)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue