From a9953dd641319905f1e83081aec1c84a781b7457 Mon Sep 17 00:00:00 2001 From: Slavi Pantaleev Date: Fri, 7 Jun 2019 15:48:13 +0300 Subject: [PATCH] Make Facebook/Telegram bridges not log to files We log to journald anyway. There's no need for double-logging. It should not that matrix-synapse logs to journald and to files, but that's likely to change in the future as well. Because Synapse's logs are insanely verbose right now (and may get dropped by journald), it's more reliable to have file-logging too. As Synapse matures and gets more stable, logging should hopefully get less, we should be able to only use journald and stop writing to files for it as well. --- roles/matrix-bridge-mautrix-facebook/defaults/main.yml | 8 +------- .../templates/config.yaml.j2 | 8 +------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/roles/matrix-bridge-mautrix-facebook/defaults/main.yml b/roles/matrix-bridge-mautrix-facebook/defaults/main.yml index a323b03c5..b9039dc6b 100644 --- a/roles/matrix-bridge-mautrix-facebook/defaults/main.yml +++ b/roles/matrix-bridge-mautrix-facebook/defaults/main.yml @@ -134,12 +134,6 @@ matrix_mautrix_facebook_configuration_yaml: | normal: format: "[%(asctime)s] [%(levelname)s@%(name)s] %(message)s" handlers: - file: - class: logging.handlers.RotatingFileHandler - formatter: normal - filename: /data/mautrix-facebook.log - maxBytes: 10485760 - backupCount: 10 console: class: logging.StreamHandler formatter: colored @@ -152,7 +146,7 @@ matrix_mautrix_facebook_configuration_yaml: | level: INFO root: level: DEBUG - handlers: [file, console] + handlers: [console] matrix_mautrix_facebook_configuration_extension_yaml: | # Your custom YAML configuration goes here. diff --git a/roles/matrix-bridge-mautrix-telegram/templates/config.yaml.j2 b/roles/matrix-bridge-mautrix-telegram/templates/config.yaml.j2 index b28546466..0a8869a6a 100644 --- a/roles/matrix-bridge-mautrix-telegram/templates/config.yaml.j2 +++ b/roles/matrix-bridge-mautrix-telegram/templates/config.yaml.j2 @@ -251,12 +251,6 @@ logging: precise: format: "[%(asctime)s] [%(levelname)s@%(name)s] %(message)s" handlers: - file: - class: logging.handlers.RotatingFileHandler - formatter: precise - filename: /data/mautrix-telegram.log - maxBytes: 10485760 - backupCount: 10 console: class: logging.StreamHandler formatter: precise @@ -269,4 +263,4 @@ logging: level: INFO root: level: DEBUG - handlers: [file, console] + handlers: [console]