+ when: ansible_distribution_major_version|int >= 8 and check_mk_socket_unit.stat.exists == False
+ notify:
+ - reload systemd daemon
+
+- name: enable xinetd configuration
+ tags:
+ - check_mk
+ lineinfile: >
+ dest=/etc/xinetd.d/check_mk
+ group=root
+ mode=0644
+ owner=root
+ regexp="^[\s]*disable[\s]*="
+ state=absent
+ when: "ansible_distribution_major_version|int < 8"