2023-01-04 14:45:37 +02:00
|
|
|
---
|
|
|
|
|
|
|
|
- name: Check existence of matrix-user-verification-service service
|
2023-02-10 14:21:31 +02:00
|
|
|
ansible.builtin.stat:
|
2023-02-06 18:20:13 +02:00
|
|
|
path: "{{ devture_systemd_docker_base_systemd_path }}/{{ matrix_user_verification_service_systemd_service_name }}"
|
2023-01-04 14:45:37 +02:00
|
|
|
register: matrix_user_verification_service_service_stat
|
|
|
|
|
2023-02-06 13:38:01 +02:00
|
|
|
- when: matrix_user_verification_service_service_stat.stat.exists | bool
|
|
|
|
block:
|
|
|
|
- name: Ensure matrix-user-verification-service is stopped
|
2023-02-10 14:21:31 +02:00
|
|
|
ansible.builtin.service:
|
2023-02-06 13:38:01 +02:00
|
|
|
name: "{{ matrix_user_verification_service_systemd_service_basename }}"
|
|
|
|
state: stopped
|
2023-02-06 17:29:25 +02:00
|
|
|
daemon_reload: true
|
2023-02-06 13:38:01 +02:00
|
|
|
register: stopping_result
|
2023-01-04 14:45:37 +02:00
|
|
|
|
2023-02-06 13:38:01 +02:00
|
|
|
- name: Ensure matrix-user-verification-service.service doesn't exist
|
2023-02-10 14:21:31 +02:00
|
|
|
ansible.builtin.file:
|
2023-02-06 18:20:13 +02:00
|
|
|
path: "{{ devture_systemd_docker_base_systemd_path }}/{{ matrix_user_verification_service_systemd_service_name }}"
|
2023-02-06 13:38:01 +02:00
|
|
|
state: absent
|
2023-01-04 14:45:37 +02:00
|
|
|
|
2023-02-06 13:38:01 +02:00
|
|
|
- name: Ensure Matrix user-verification-service paths don't exist
|
2023-02-10 14:21:31 +02:00
|
|
|
ansible.builtin.file:
|
2023-02-06 13:38:01 +02:00
|
|
|
path: "{{ matrix_user_verification_service_base_path }}"
|
|
|
|
state: absent
|