Environement variable that indicates borgmatic's logfile #413
Labels
No Label
bug
data loss
design finalized
good first issue
new feature area
question / support
security
waiting for response
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: borgmatic-collective/borgmatic#413
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What I'm trying to do and why
I'd like a way to get logs of borg and/or borgmatic output.
I'm using pushover to notify me about backup starting/ending/error but I'd like to join the log when starting/ending.
Other notes / implementation ideas
It would be great to have a environment variable reachable from
after_backup
,after_everything
... that indicate the log file borgmatic is writting to (--log-file ?).So it could be used like this :
Environment
borgmatic version: 1.5.13
borgmatic installation method: pip (debian package outdated)
Borg version: 1.1.9
Python version: 3.7.3
operating system and version: Debian GNU/Linux 10 (buster)
I apologize for the lengthy delay in responding to this. This seems reasonable to me—as long it's clear it'll only work if borgmatic is actually logging to a file via
--log-file
!Implemented by @diivi in https://github.com/borgmatic-collective/borgmatic/pull/68. The documentation will be here shortly: https://torsion.org/borgmatic/docs/how-to/add-preparation-and-cleanup-steps-to-backups/#variable-interpolation
The summary though is that there's a new
log_file
hook variable you can use in your command hooks. E.g.:This has been released in borgmatic 1.7.12! Thanks for the suggestion.