mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-07 22:06:05 +01:00
bug fix: in backups v2
This commit is contained in:
@@ -1859,7 +1859,7 @@ class BackupManager:
|
|||||||
|
|
||||||
statusFile = f'/home/cyberpanel/{domain}_rustic_backup_log'
|
statusFile = f'/home/cyberpanel/{domain}_rustic_backup_log'
|
||||||
|
|
||||||
if ACLManager.CheckStatusFilleLoc(statusFile):
|
if ACLManager.CheckStatusFilleLoc(statusFile, domain):
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
data_ret = {'abort': 1, 'installStatus': 0, 'installationProgress': "100",
|
data_ret = {'abort': 1, 'installStatus': 0, 'installationProgress': "100",
|
||||||
|
|||||||
@@ -881,13 +881,19 @@ class ACLManager:
|
|||||||
return 1
|
return 1
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def CheckStatusFilleLoc(statusFile):
|
def CheckStatusFilleLoc(statusFile, domain=None):
|
||||||
TemFilePath = statusFile.split('panel/')[1]
|
TemFilePath = statusFile.split('panel/')[1]
|
||||||
|
|
||||||
try:
|
try:
|
||||||
value = int(TemFilePath)
|
value = int(TemFilePath)
|
||||||
print(value)
|
print(value)
|
||||||
except:
|
except:
|
||||||
|
if domain != None:
|
||||||
|
value = statusFile.split('cyberpanel/')[1]
|
||||||
|
#logging.writeToFile(f'value of log file {value}')
|
||||||
|
if value == f'{domain}_rustic_backup_log':
|
||||||
|
return 1
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
if (statusFile[:18] != "/home/cyberpanel/." or statusFile[:16] == "/home/cyberpanel" or statusFile[
|
if (statusFile[:18] != "/home/cyberpanel/." or statusFile[:16] == "/home/cyberpanel" or statusFile[
|
||||||
|
|||||||
Reference in New Issue
Block a user