Bladeren bron

Configure rspamd to accept logwatch's logs

Sometimes logwatch logs will contain URLs and domain names that trip
on abuse lists.    Use a custom filter to remove these checks.
Mike Ashley 7 jaren geleden
bovenliggende
commit
257a2252b5

+ 3
- 0
roles/monitoring/handlers/main.yml Bestand weergeven

@@ -3,3 +3,6 @@
3 3
 
4 4
 - name: restart collectd
5 5
   service: name=collectd state=restarted
6
+
7
+- name: restart rspamd
8
+  service: name=rspamd state=restarted

+ 4
- 0
roles/monitoring/tasks/logwatch.yml Bestand weergeven

@@ -9,6 +9,10 @@
9 9
 - name: Configure logwatch
10 10
   template: src=etc_logwatch_conf_logwatch.conf.j2 dest=/etc/logwatch/conf/logwatch.conf
11 11
 
12
+- name: Configure rspamd to let logs through
13
+  template: src=etc_rspamd_rspamd.conf.local.j2 dest=/etc/rspamd/rspamd.conf.local
14
+  notify: restart rspamd
15
+
12 16
 - name: Remove logwatch's dist cronjob
13 17
   file: state=absent path=/etc/cron.daily/00logwatch
14 18
 

+ 12
- 0
roles/monitoring/templates/etc_rspamd_rspamd.conf.local.j2 Bestand weergeven

@@ -0,0 +1,12 @@
1
+settings {
2
+  accept_logs {
3
+    id = "accept_logs";
4
+    priority = "high";
5
+    from = "root@{{ domain }}";
6
+    rcpt = "root@{{ domain }}";
7
+    apply {
8
+      groups_disabled = ["surbl"];
9
+      symbols_disabled = ["R_SUSPICIOUS_URL"];
10
+    }
11
+  }
12
+}

Laden…
Annuleren
Opslaan