Optionally log verbose output to a file instead of stdout#391
Merged
Conversation
Co-authored-by: Steven Honson <[email protected]> Co-authored-by: Michael Renner <[email protected]>
Co-authored-by: Steven Honson <[email protected]>
gnawhleinad
reviewed
Apr 21, 2018
| # When verbose output is enabled with `-v`, it's written to stdout by default. If | ||
| # you'd prefer it to be written to a separate file, set this option. | ||
| # | ||
| # GHE_VERBOSE_LOG="/var/log/backup-verbose.log" |
Contributor
There was a problem hiding this comment.
nit: 🔥 the space to be consistent with the other commented-out examples.
gnawhleinad
approved these changes
Apr 21, 2018
gnawhleinad
left a comment
Contributor
There was a problem hiding this comment.
Other than the nit comment, looks good to me!
Merged
dooleydevin
pushed a commit
that referenced
this pull request
Aug 16, 2023
…p-restore-secret-scanning-encryption-keys Backport 351 for 3.9: Backup and restore secret scanning encrypted secrets encryption keys
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Verbose logging is super helpful for debugging backup problems, but writing all verbose output to stdout means that it can't easily be enabled if stdout should remain easily readable or mailable. For example, an admin might like to receive an email via cron after a backup has completed, with the text showing the backup steps and confirming when the backup run finished.
This PR adds a
GHE_VERBOSE_LOGsetting, which may be pointed to a file that the verbose output will be written to. If a backup fails, the log can then be used to investigate the problem further./cc @snh @terrorobe