diff --git a/plogical/Backupsv2.py b/plogical/Backupsv2.py index 7924e46ad..0c1347d0d 100644 --- a/plogical/Backupsv2.py +++ b/plogical/Backupsv2.py @@ -110,7 +110,13 @@ pass = {ObsecurePassword} #command = f'chown cyberpanel:cyberpanel {self.FinalPathRuctic}' #ProcessUtilities.executioner(command) + command = f'chown {self.website.externalApp}:{self.website.externalApp} {self.FinalPathRuctic}/config.json' + ProcessUtilities.executioner(command) + command = f'rustic -r {self.repo} backup {self.FinalPathRuctic}/config.json --password "" --tag {parent}' + ProcessUtilities.executioner(command, self.website.externalApp) + + command = f'chown cyberpanel:cyberpanel {self.FinalPathRuctic}/config.json' ProcessUtilities.executioner(command) def InitiateBackup(self): diff --git a/serverStatus/views.py b/serverStatus/views.py index 1ba3ed931..1e93cd190 100755 --- a/serverStatus/views.py +++ b/serverStatus/views.py @@ -455,9 +455,11 @@ def refreshLicense(request): {'domain': 'cyberpanel.net', 'BasePath': '/home/backup', 'BackupDatabase': 1, 'BackupData': 1, 'BackupEmails': 1, 'BackendName': 'testremote'}) RcloneData = {"name":'testremote', "host":"staging.cyberpanel.net", "user": "abcds2751", "port": "22", "password":"hosting",} - cpbuv2.SetupRcloneBackend(CPBackupsV2.SFTP, RcloneData) + #cpbuv2.SetupRcloneBackend(CPBackupsV2.SFTP, RcloneData) cpbuv2.InitiateBackup() + + #cpbuv2.InstallRustic() final_dic = {'status': 1}