- hosts: all remote_user: root tasks: - name: check for ssl cert stat: path: /home/ircd/ircd/etc/ssl.pem register: ssl_exists - name: get ssl fingerprint command: /home/ircd/ircd/bin/solanum-mkfingerprint sha512 /home/ircd/ircd/etc/ssl.pem register: ssl_fingerprint when: ssl_exists.stat.exists - name: create ircd.conf template: src: ircd.j2 dest: /home/ircd/ircd/etc/ircd.conf - name: create ircd.motd template: src: motd.j2 dest: /home/ircd/ircd/etc/ircd.motd - name: copy oper CHALLENGE keys copy: src: challenge/ dest: /home/ircd/ircd/challenge/ - name: create openrc service template: src: openrc.j2 dest: /etc/init.d/solanum mode: 0755 when: ansible_distribution == 'Alpine' - name: create systemd service template: src: systemd.j2 dest: /etc/systemd/system/solanum.service mode: 0755 when: ansible_distribution == 'Debian' - name: enable service service: name: solanum state: started enabled: yes ignore_errors: yes - name: reload solanum command: killall -1 solanum