Fix failure trying to stop orphaned systemd services

Fixes https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/1461
This commit is contained in:
Slavi Pantaleev 2021-12-17 17:18:18 +02:00
parent 067bea25a8
commit 4625b34acc

View file

@ -8,6 +8,7 @@
name: "{{ item.key }}"
state: stopped
with_dict: "{{ ansible_facts.services|default({})|dict2items|selectattr('key', 'match', 'matrix-synapse-worker-.+\\.service')|list|items2dict }}"
when: "item.value['status'] != 'not-found'" # see https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/1461
- name: Find worker configs to be cleaned
find: