--- - name: restart_sshd become: true ansible.builtin.service: name: sshd state: restarted - name: restart_fail2ban become: true ansible.builtin.service: name: fail2ban state: restarted # Guarded: a config change still notifies this handler when graylog_enabled is # false, and an unconditional restart would start the service the fluent-bit # task just stopped. - name: restart fluent-bit become: true ansible.builtin.systemd: name: fluent-bit state: restarted when: graylog_enabled | bool - name: restart_journald become: true ansible.builtin.systemd: name: systemd-journald state: restarted