--- - name: "[systemd] Disable and stop service: zigbee2mqtt" systemd: name: "zigbee2mqtt" enabled: no state: stopped when: - ansible_service_mgr == "systemd" - name: "[Archlinux] Remove package: zigbee2mqtt" pacman: name: zigbee2mqtt state: absent when: - ansible_distribution == "Archlinux" - name: "Delete leftovers" file: path: "{{item}}" state: absent with_items: - /etc/zigbee2mqtt