diff --git a/app/im/config/homeserver.yaml b/app/im/config/homeserver.yaml index 8204f14..0caacfe 100644 --- a/app/im/config/homeserver.yaml +++ b/app/im/config/homeserver.yaml @@ -804,7 +804,7 @@ database: # A yaml python logging config file as described by # https://docs.python.org/3.7/library/logging.config.html#configuration-dictionary-schema # -log_config: "/data/matrix.home.adnab.me.log.config" +log_config: "/etc/matrix-synapse/synapse.log.config.yaml" ## Ratelimiting ## diff --git a/app/im/config/synapse.log.config.yaml b/app/im/config/synapse.log.config.yaml new file mode 100644 index 0000000..0b5622e --- /dev/null +++ b/app/im/config/synapse.log.config.yaml @@ -0,0 +1,23 @@ +version: 1 + +formatters: + precise: + format: '%(asctime)s - %(name)s - %(lineno)d - %(levelname)s - %(request)s - %(message)s' + + +handlers: + console: + class: logging.StreamHandler + formatter: precise + +loggers: + synapse.storage.SQL: + # beware: increasing this to DEBUG will make synapse log sensitive + # information such as access tokens. + level: INFO + +root: + level: INFO + handlers: [console] + +disable_existing_loggers: false diff --git a/app/im/deploy/im.hcl b/app/im/deploy/im.hcl index 3cf4e95..6378e82 100644 --- a/app/im/deploy/im.hcl +++ b/app/im/deploy/im.hcl @@ -66,7 +66,7 @@ job "im" { volumes = [ "secrets:/etc/matrix-synapse", "../alloc/data:/ephemeral", - "/mnt/ssd/synapse:/data", + "/mnt/garage-staging/synapse-data:/data", ] } @@ -75,6 +75,11 @@ job "im" { destination = "secrets/homeserver.yaml" } + template { + data = file("../config/synapse.log.config.yaml") + destination = "secrets/synapse.log.config.yaml" + } + template { data = "{{ key \"secrets/synapse/signing_key\" }}" destination = "secrets/signing_key"