This commit is contained in:
brent s committed 2019-05-31 16:50:43 -04:00
1 parent a89a6ec94b
commit 7eee1c4658
3 files changed
+36 -3

No files matched your search

+4 -1
View File
@@ -83,7 +83,10 @@ class Backup(object):
if self.args['verbose']:
handlers.append(logging.StreamHandler())
if has_systemd:
h = journal.JournalHandler()
try:
h = journal.JournalHandler()
except AttributeError:
h = journal.JournaldLogHandler()
h.setFormatter(_journalfmt)
h.setLevel(loglvls[self.args['loglevel']])
self.logger.addHandler(h)