mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-09 14:56:10 +01:00
bug fix: wp staging
This commit is contained in:
@@ -27,7 +27,8 @@ class ApplicationInstaller(multi.Thread):
|
|||||||
multi.Thread.__init__(self)
|
multi.Thread.__init__(self)
|
||||||
self.installApp = installApp
|
self.installApp = installApp
|
||||||
self.extraArgs = extraArgs
|
self.extraArgs = extraArgs
|
||||||
self.tempStatusPath = self.extraArgs['tempStatusPath']
|
if extraArgs != None:
|
||||||
|
self.tempStatusPath = self.extraArgs['tempStatusPath']
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
try:
|
try:
|
||||||
|
|||||||
@@ -187,12 +187,12 @@ class ProcessUtilities(multi.Thread):
|
|||||||
sock = ret[0]
|
sock = ret[0]
|
||||||
|
|
||||||
if user == None:
|
if user == None:
|
||||||
logging.writeToFile(ProcessUtilities.token + command)
|
#logging.writeToFile(ProcessUtilities.token + command)
|
||||||
sock.sendall((ProcessUtilities.token + command).encode('utf-8'))
|
sock.sendall((ProcessUtilities.token + command).encode('utf-8'))
|
||||||
else:
|
else:
|
||||||
command = '%s-u %s %s' % (ProcessUtilities.token, user, command)
|
command = '%s-u %s %s' % (ProcessUtilities.token, user, command)
|
||||||
command = command.replace('sudo', '')
|
command = command.replace('sudo', '')
|
||||||
logging.writeToFile(ProcessUtilities.token + command)
|
#logging.writeToFile(ProcessUtilities.token + command)
|
||||||
sock.sendall(command.encode('utf-8'))
|
sock.sendall(command.encode('utf-8'))
|
||||||
|
|
||||||
data = ""
|
data = ""
|
||||||
@@ -207,7 +207,7 @@ class ProcessUtilities(multi.Thread):
|
|||||||
logging.writeToFile('Some data could not be decoded to str, error message: %s' % str(msg))
|
logging.writeToFile('Some data could not be decoded to str, error message: %s' % str(msg))
|
||||||
|
|
||||||
sock.close()
|
sock.close()
|
||||||
logging.writeToFile('Final data: %s.' % (str(data)))
|
#logging.writeToFile('Final data: %s.' % (str(data)))
|
||||||
|
|
||||||
return data
|
return data
|
||||||
except BaseException as msg:
|
except BaseException as msg:
|
||||||
|
|||||||
@@ -88,6 +88,8 @@ class StagingSetup(multi.Thread):
|
|||||||
|
|
||||||
data = open(configPath, 'r').readlines()
|
data = open(configPath, 'r').readlines()
|
||||||
|
|
||||||
|
logging.writeToFile(str(type(data)))
|
||||||
|
|
||||||
for items in data:
|
for items in data:
|
||||||
if items.find('DB_NAME') > -1:
|
if items.find('DB_NAME') > -1:
|
||||||
try:
|
try:
|
||||||
@@ -161,7 +163,7 @@ class StagingSetup(multi.Thread):
|
|||||||
|
|
||||||
return 0
|
return 0
|
||||||
except BaseException as msg:
|
except BaseException as msg:
|
||||||
mesg = '%s. [404]' % (str(msg))
|
mesg = '%s. [168][404]' % (str(msg))
|
||||||
logging.statusWriter(self.tempStatusPath, mesg)
|
logging.statusWriter(self.tempStatusPath, mesg)
|
||||||
|
|
||||||
def startSyncing(self):
|
def startSyncing(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user