Skip to content

Commit

Permalink
Fix bugs in rclone_kapsi.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
AgenttiX committed Jul 31, 2023
1 parent 7061716 commit b2320f6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions backup/rclone_kapsi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,14 @@ set -e
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
REPO_DIR="$(dirname "${SCRIPT_DIR}")"
TIMESTAMP="$(date +%Y-%m-%d_%H-%M-%S)"
LOG_PATH="${REPO_DIR}/logs/rsync_kapsi_${TIMESTAMP}.txt"
LOG_PATH="${REPO_DIR}/logs/rclone_kapsi_${TIMESTAMP}.txt"

# Warning: the --delete-excluded flag will delete files on the target that are not part of the backup.
# First run the backup without --delete-excluded to see that it goes to the correct empty folder,
# and doesn't mess with other files on the target machine!
rclone sync \
--progress \
--exclude-from="${SCRIPT_DIR}/rsync_exclude.txt" \
--delete-excluded \
/mnt/files \
kapsi-crypt:/files |& tee -a "${LOG_PATH}"
# --delete-excluded

0 comments on commit b2320f6

Please sign in to comment.