--- - name: Deploy SSH config template: src: sshd_config.j2 dest: /etc/ssh/sshd_config owner: root group: root mode: '0600' notify: Restart ssh - name: SSH key for access authorized_key: user: "{{ user }}" state: present key: "{{ lookup('file', 'files/id_ed25519.pub') }}" notify: Restart ssh