Browse Source

move logs to /var

master
histausse 1 year ago
parent
commit
41ec64e26e
Signed by: histausse
GPG Key ID: 67486F107F62E9E9
  1. 8
      roles/matrix-bridge-discord/tasks/main.yml
  2. 6
      roles/matrix-bridge-discord/templates/config.yaml
  3. 8
      roles/matrix-bridge-facebook/tasks/main.yml
  4. 2
      roles/matrix-bridge-facebook/templates/config.yaml

8
roles/matrix-bridge-discord/tasks/main.yml

@ -89,6 +89,14 @@
dest: /etc/systemd/system/bridge_discord.service
notify: Restart the discord bridge
- name: Ensure the log directory exists
file:
path: /var/log/bridge_discord
state: directory
group: root
owner: root
mode: u=rwx,g=rx,o=
- name: Enable the daemon
systemd:
name: bridge_discord

6
roles/matrix-bridge-discord/templates/config.yaml

@ -49,12 +49,12 @@ logging:
console: "warn" #silly, verbose, info, http, warn, error, silent
lineDateFormat: "MMM-D HH:mm:ss.SSS" # This is in moment.js format
files:
- file: "debug.log"
- file: "/var/log/bridge_discord/debug.log"
disable:
- "PresenceHandler" # Will not capture presence logging
- file: "warn.log" # Will capture warnings
- file: "/var/log/bridge_discord/warn.log" # Will capture warnings
level: "warn"
- file: "botlogs.log" # Will capture logs from DiscordBot
- file: "/var/log/bridge_discord/botlogs.log" # Will capture logs from DiscordBot
level: "info"
enable:
- "DiscordBot"

8
roles/matrix-bridge-facebook/tasks/main.yml

@ -68,6 +68,14 @@
dest: /etc/matrix-synapse/facebook-registration.yaml
state: link
- name: Ensure the log directory exists
file:
path: /var/log/bridge_facebook
state: directory
group: nogroup
owner: mautrix-facebook
mode: u=rwx,g=rx,o=
- name: Copy the daemon configuration
template:
src: bridge_facebook.service

2
roles/matrix-bridge-facebook/templates/config.yaml

@ -247,7 +247,7 @@ logging:
file:
class: logging.handlers.RotatingFileHandler
formatter: normal
filename: ./mautrix-facebook.log
filename: /var/log/bridge_facebook/mautrix-facebook.log
maxBytes: 10485760
backupCount: 10
console:

Loading…
Cancel
Save