From 6497247eb431ff0b9ce9f996e867983a79e9aef5 Mon Sep 17 00:00:00 2001 From: Usman Nasir Date: Fri, 26 Mar 2021 00:36:41 +0500 Subject: [PATCH] bug fix in backup encoding --- plogical/backupUtilities.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plogical/backupUtilities.py b/plogical/backupUtilities.py index 6efde5870..e38753e41 100755 --- a/plogical/backupUtilities.py +++ b/plogical/backupUtilities.py @@ -374,7 +374,9 @@ class backupUtilities: # copy_tree('/home/%s/public_html' % domainName, '%s/%s' % (tempStoragePath, 'public_html')) command = 'cp -R /home/%s/public_html %s/public_html' % (domainName, tempStoragePath) - ProcessUtilities.executioner(command) + + if ProcessUtilities.normalExecutioner(command) == 0: + raise BaseException('Failed to run %s.' % (command)) # make_archive(os.path.join(tempStoragePath,"public_html"), 'gztar', os.path.join("/home",domainName,"public_html")) @@ -1939,7 +1941,7 @@ def submitBackupCreation(tempStoragePath, backupName, backupPath, backupDomain): + backupName + " --backupPath " + backupPath + ' --backupDomain ' + backupDomain + ' --metaPath %s' % ( result[2]) - output = ProcessUtilities.outputExecutioner(execPath) + output = ProcessUtilities.outputExecutioner(execPath, website.externalApp) if output.find('[5009]') > -1: logging.CyberCPLogFileWriter.writeToFile(output)