ansible/roles/rsyslog_collector/tasks/main.yml
Jeltz f7183095c1
Some checks failed
continuous-integration/drone/push Build is failing
Add explicit permissions for directories
2021-03-01 02:26:22 +01:00

27 lines
598 B
YAML

---
- name: Install rsyslog-relp if needed
become: true
apt:
name: rsyslog-relp
state: latest
when: "rsyslog_inputs | selectattr('proto', 'eq', 'relp') | list"
- name: Ensure log storage directory exists
become: true
file:
path: "{{ rsyslog_collector_base_dir }}"
state: directory
owner: root
group: adm
mode: u=rwx,g=rwx,o=
- name: Deploy rsyslog input configuration file
become: true
template:
src: 20-collector.conf.j2
dest: /etc/rsyslog.d/20-collector.conf
owner: root
group: root
mode: u=rw,g=r,o=r
notify: Restart rsyslog
...