From 5e95f37c12b1394983fadd51c9609d6d515a9ea1 Mon Sep 17 00:00:00 2001 From: antifallobst Date: Sun, 17 Dec 2023 21:21:34 +0100 Subject: [PATCH] fix(worker/mailcow): fixed path and added error message to output --- src/backend/backup/worker/mod.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backend/backup/worker/mod.rs b/src/backend/backup/worker/mod.rs index c433b90..286b488 100644 --- a/src/backend/backup/worker/mod.rs +++ b/src/backend/backup/worker/mod.rs @@ -65,14 +65,14 @@ fn perform_backup(backup: backup::Backup) -> Result<()> { create_dir_all(&tmp)?; let status = Command::new("bash") - .arg(format!("{dir}/helper-scripts/backup_and_restore.sh")) + .arg(format!("{dir}helper-scripts/backup_and_restore.sh")) .arg("backup") .arg("all") .env("MAILCOW_BACKUP_LOCATION", &tmp) .status()?; if !status.success() { - return Err(Error::msg("Failed to create mailcow backup}")); + bail!("Failed to create mailcow backup: {}", status); } add_dir_to_archive(&mut archive, &Path::new(&tmp), "mailcow", options)?;