diff options
author | Stonewall Jackson <stonewall@sacredheartsc.com> | 2023-02-04 01:23:43 -0500 |
---|---|---|
committer | Stonewall Jackson <stonewall@sacredheartsc.com> | 2023-02-04 01:52:13 -0500 |
commit | 0261e875679f1bf63c8d689da7fc7e014597885d (patch) | |
tree | 3f19cd74a0c1070944f75437f30b098d6ef2ffcb /roles/rsyslog_client/tasks | |
download | selfhosted-0261e875679f1bf63c8d689da7fc7e014597885d.tar.gz selfhosted-0261e875679f1bf63c8d689da7fc7e014597885d.zip |
initial commit
Diffstat (limited to 'roles/rsyslog_client/tasks')
-rw-r--r-- | roles/rsyslog_client/tasks/main.yml | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/roles/rsyslog_client/tasks/main.yml b/roles/rsyslog_client/tasks/main.yml new file mode 100644 index 0000000..c610d6d --- /dev/null +++ b/roles/rsyslog_client/tasks/main.yml @@ -0,0 +1,27 @@ +- name: install rsyslog + dnf: + name: '{{ rsyslog_packages }}' + state: present + +- name: request TLS certificate + include_role: + name: getcert_request + vars: + certificate_sans: ['{{ ansible_fqdn }}'] + certificate_service: syslog + certificate_path: '{{ rsyslog_certificate_path }}' + certificate_key_path: '{{ rsyslog_certificate_key_path }}' + certificate_hook: systemctl restart rsyslog + when: rsyslog_tls + +- name: generate rsyslog configuration + template: + src: etc/rsyslog.conf.j2 + dest: /etc/rsyslog.conf + notify: restart rsyslog + +- name: enable rsyslog + systemd: + name: rsyslog + enabled: yes + state: started |