# SPDX-License-Identifier: MIT - name: 'Gather service facts' ansible.builtin.service_facts: - name: 'If ''sysstat.service'' exists make sure it''s running' when: '''sysstat.service'' in ansible_facts[''services'']' ansible.builtin.service: name: 'sysstat.service' state: 'started' enabled: true