Suggestion: config option to automatically accept Borg warning of repository location change #209

Closed
opened 2019-08-25 00:26:20 +00:00 by adatum · 6 comments

Currently if the repository location changes, Borg issues a warning which requires a y/N response. The part of the warning containing the prompt is not visible when using borgmatic.

It would be good to:

  • have prompts visible so that the user can respond, and/or preferably
  • add a config option to automatically respond "y" to the Borg warning, via the BORG_RELOCATED_REPO_ACCESS_IS_OK Borg environment variable (see the automatic "answerers" section).
Currently if the repository location changes, Borg issues a warning which requires a y/N response. The part of the warning containing the prompt is not visible when using borgmatic. It would be good to: * have prompts visible so that the user can respond, and/or preferably * add a config option to automatically respond "y" to the Borg warning, via the BORG_RELOCATED_REPO_ACCESS_IS_OK [Borg environment variable](https://borgbackup.readthedocs.io/en/stable/usage/general.html#environment-variables) (see the automatic "answerers" section).
Owner

Thank you for suggesting this! Just implemented in master. Now, instead of borgmatic hanging while Borg prompts for input, it defaults to setting BORG_RELOCATED_REPO_ACCESS_IS_OK=no when invoking Borg. And you can override this with a new boolean configuration file option in borgmatic's storage section: relocated_repo_access_is_ok.

I'll comment here when this makes its way into a borgmatic release.

Thank you for suggesting this! Just implemented in master. Now, instead of borgmatic hanging while Borg prompts for input, it defaults to setting `BORG_RELOCATED_REPO_ACCESS_IS_OK=no` when invoking Borg. And you can override this with a new boolean configuration file option in borgmatic's `storage` section: `relocated_repo_access_is_ok`. I'll comment here when this makes its way into a borgmatic release.
Author

Thanks! Given the automated nature of borgmatic, I think this config option makes sense.

Note that borgmatic does not hang. The prompt asking for a y/N response simply is not displayed at the moment the prompt is asked. "y" + Enter still functions, and then reveals the prompt. Similarly, the prompt is revealed after hitting Ctrl+C when borgmatic "hangs".

Thanks! Given the automated nature of borgmatic, I think this config option makes sense. Note that borgmatic does not hang. The prompt asking for a y/N response simply is not displayed at the moment the prompt is asked. "y" + Enter still functions, and then reveals the prompt. Similarly, the prompt is revealed after hitting Ctrl+C when borgmatic "hangs".
Owner

Got it, thanks for the explanation. Still pretty unexpected behavior from a user's perspective though! The new version will instead simply default to a N response so there are no hidden prompts.

Got it, thanks for the explanation. Still pretty unexpected behavior from a user's perspective though! The new version will instead simply default to a `N` response so there are no hidden prompts.
Owner

And now released as part of borgmatic 1.3.15!

And now released as part of borgmatic 1.3.15!

@witten, I have to say, it is a real gift to be using a tool that is so actively maintained. I had the same issue today, googled it, found this ticket, updated the borgmatic version inside the Synology package I am using, and voila! Thank you so much :)

@witten, I have to say, it is a real gift to be using a tool that is so actively maintained. I had the same issue today, googled it, found this ticket, updated the borgmatic version inside the Synology package I am using, and voila! Thank you so much :)
Owner

Thanks for the kind words! I'm so glad to hear borgmatic is working out for you.

Thanks for the kind words! I'm so glad to hear borgmatic is working out for you.
Sign in to join this conversation.
No Milestone
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: borgmatic-collective/borgmatic#209
No description provided.