Skip to content
Discussion options

You must be logged in to vote

Not in the path field itself: backrest passes the plan's paths to restic exactly as written, with no shell and no date expansion, so $(date ...) stays literal. You can get the same result with a hook and restic's --files-from, and backrest (1.13.0 and later) allows a plan with no paths when the backup flags supply them (its validation says "unless backup_flags supplies paths, e.g. --files-from").

  1. Add a hook to the plan: type Command, condition CONDITION_SNAPSHOT_START (it runs before restic starts), error behavior ON_ERROR_CANCEL, with a script that writes the newest snapshot directory to a file and fails if there is none:

    latest=$(ls -d /tank/.zfs/snapshot/auto-*_00-00 | tail -n 1)
    [ -n "

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by BEBU88
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants