--- - name: Reload systemd daemon systemd: daemon_reload: yes - name: Enable and start monerod systemd: name: monerod enabled: yes state: started - name: Flush handlers so monerod is running before we ask it anything meta: flush_handlers # Generous, and non-fatal. On a first start monerod initialises LMDB on a fresh # 500 GB disk before it opens the RPC port; on a later start it is quick. A # timeout here is not a deployment failure, and the health check is the thing # that decides whether the node is actually well. - name: Wait for the monerod RPC port ansible.builtin.wait_for: port: "{{ monero_rpc_port }}" host: "{{ monero_rpc_bind_ip }}" delay: 5 timeout: 180 ignore_errors: yes - name: Check the monerod service status systemd: name: monerod register: monero_service_status changed_when: false - name: Display the monerod service status ansible.builtin.debug: msg: "monerod is {{ 'running' if monero_service_status.status.ActiveState == 'active' else 'NOT running' }}"