|
|
@ -121,7 +121,7 @@ func snapBackup(snap snapHelper, localDir, targetDir string) {
|
|
|
|
defer snap.Wg.Done()
|
|
|
|
defer snap.Wg.Done()
|
|
|
|
_ = snapshotRepo.UpdateStatus(snap.Status.ID, map[string]interface{}{"backup_data": constant.Running})
|
|
|
|
_ = snapshotRepo.UpdateStatus(snap.Status.ID, map[string]interface{}{"backup_data": constant.Running})
|
|
|
|
status := constant.StatusDone
|
|
|
|
status := constant.StatusDone
|
|
|
|
if err := handleSnapTar(localDir, targetDir, "1panel_backup.tar.gz", "./system;"); err != nil {
|
|
|
|
if err := handleSnapTar(localDir, targetDir, "1panel_backup.tar.gz", "./system;./system_snapshot;"); err != nil {
|
|
|
|
status = err.Error()
|
|
|
|
status = err.Error()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
snap.Status.BackupData = status
|
|
|
|
snap.Status.BackupData = status
|
|
|
|