Skip to content

Commit

Permalink
bug fix: mail domain skip while restore
Browse files Browse the repository at this point in the history
  • Loading branch information
usmannasir committed Feb 9, 2020
1 parent 4611c32 commit 1c3970a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@
.LSOverride
*.pyc
.idea
venv
11 changes: 11 additions & 0 deletions plogical/backupUtilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -628,6 +628,16 @@ def startRestore(backupName, dir):
for childDomain in childDomains:

domain = childDomain.find('domain').text

## mail domain check

mailDomain = 'mail.%s' % (masterDomain)

if domain == mailDomain:
continue

## Mail domain check

phpSelection = childDomain.find('phpSelection').text
path = childDomain.find('path').text

Expand Down Expand Up @@ -668,6 +678,7 @@ def startRestore(backupName, dir):

continue
else:
logging.CyberCPLogFileWriter.writeToFile('Error domain %s' % (domain))
logging.CyberCPLogFileWriter.statusWriter(status, "Error Message: " + retValues[1] + ". Not able to create child domains, aborting. [635][5009]")
return 0
except BaseException as msg:
Expand Down

0 comments on commit 1c3970a

Please sign in to comment.