--- - name: Restart SSH ansible.builtin.service: name: "{{ 'sshd' if ansible_facts.os_family in ['RedHat','Rocky','AlmaLinux','Fedora','OracleLinux','Suse'] else 'ssh' }}" state: restarted