ansible-role-postfix/tasks/rsyslog.yml
2023-09-23 09:05:01 +02:00

14 lines
437 B
YAML

---
- name: "Rsyslog | Disable logging of IP addresses"
ansible.builtin.copy:
src: rsyslog.d/mail.conf
dest: /etc/rsyslog.d/mail.conf
mode: "0644"
notify: restart rsyslog
- name: "Rsyslog | Disable mail logging to syslog"
ansible.builtin.replace:
path: /etc/rsyslog.conf
regexp: "^\\*\\.\\*(?!.*(mail\\.none).*$).*"
replace: "*.*;auth,authpriv.none,mail.none -/var/log/syslog"
notify: restart rsyslog