From 96aa4e1e5b0d9bd439656a6fca3b3a92c8d4c88d Mon Sep 17 00:00:00 2001 From: Anthony Date: Wed, 8 Jan 2025 01:24:44 +0800 Subject: [PATCH] Added uninstall script --- manifest.jps | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/manifest.jps b/manifest.jps index 10ea79e..d7931fe 100644 --- a/manifest.jps +++ b/manifest.jps @@ -360,4 +360,14 @@ actions: - curl -O https://deploy-proxy.mightybox.io/addons/mb-backup-manager/raw/branch/main/scripts/imports/check_backup_repo.sh - curl -O https://deploy-proxy.mightybox.io/addons/mb-backup-manager/raw/branch/main/scripts/imports/check_repo_stats.sh - chmod +x /home/litespeed/mb-backups/*.sh - - sudo chown -R litespeed:litespeed /home/litespeed/mb-backups \ No newline at end of file + - sudo chown -R litespeed:litespeed /home/litespeed/mb-backups + + removeScripts: + - cmd[cp]: + user: root + commands: + # Remove the crontab entry for the add-on + - (crontab -l | grep -v "${globals.scriptPath}/manage_backup_schedule.sh" | crontab -) || true + - rm -rf "${globals.scriptPath}" # Use globals.scriptPath + - rm -f /etc/restic-password + - rm -f /etc/logrotate.d/backup-addon \ No newline at end of file