--- - name: Check existence of SearXNG systemd service ansible.builtin.stat: path: "{{ devture_systemd_docker_base_systemd_path }}/{{ searxng_identifier }}.service" register: searxng_service_stat - when: searxng_service_stat.stat.exists | bool block: - name: Ensure SearXNG systemd service is stopped ansible.builtin.service: name: "{{ searxng_identifier }}" state: stopped enabled: false daemon_reload: true - name: Ensure SearXNG systemd service does not exist ansible.builtin.file: path: "{{ devture_systemd_docker_base_systemd_path }}/{{ searxng_identifier }}.service" state: absent - name: Ensure SearXNG path doesn't exist ansible.builtin.file: path: "{{ searxng_base_path }}" state: absent