@ -6,19 +6,19 @@
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal-daemon.service"
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal-daemon.service"
register : matrix_mautrix_signal_daemon_service_stat
register : matrix_mautrix_signal_daemon_service_stat
- when : matrix_mautrix_signal_daemon_service_stat.stat.exists | bool
block:
- name : Ensure matrix-mautrix-signal-daemon is stopped
- name : Ensure matrix-mautrix-signal-daemon is stopped
ansible.builtin.service:
ansible.builtin.service:
name : matrix-mautrix-signal-daemon
name : matrix-mautrix-signal-daemon
state : stopped
state : stopped
enabled : false
enabled : false
daemon_reload : true
daemon_reload : true
when : "matrix_mautrix_signal_daemon_service_stat.stat.exists"
- name : Ensure matrix-mautrix-signal-daemon.service doesn't exist
- name : Ensure matrix-mautrix-signal-daemon.service doesn't exist
ansible.builtin.file:
ansible.builtin.file:
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal-daemon.service"
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal-daemon.service"
state : absent
state : absent
when : "matrix_mautrix_signal_daemon_service_stat.stat.exists"
# Bridge service
# Bridge service
- name : Check existence of matrix-mautrix-signal service
- name : Check existence of matrix-mautrix-signal service
@ -26,22 +26,16 @@
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal.service"
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal.service"
register : matrix_mautrix_signal_service_stat
register : matrix_mautrix_signal_service_stat
- when : matrix_mautrix_signal_service_stat.stat.exists | bool
block:
- name : Ensure matrix-mautrix-signal is stopped
- name : Ensure matrix-mautrix-signal is stopped
ansible.builtin.service:
ansible.builtin.service:
name : matrix-mautrix-signal
name : matrix-mautrix-signal
state : stopped
state : stopped
enabled : false
enabled : false
daemon_reload : true
daemon_reload : true
when : "matrix_mautrix_signal_service_stat.stat.exists"
- name : Ensure matrix-mautrix-signal.service doesn't exist
- name : Ensure matrix-mautrix-signal.service doesn't exist
ansible.builtin.file:
ansible.builtin.file:
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal.service"
path : "{{ devture_systemd_docker_base_systemd_path }}/matrix-mautrix-signal.service"
state : absent
state : absent
when : "matrix_mautrix_signal_service_stat.stat.exists"
# All services
- name : Ensure systemd reloaded after matrix-mautrix-signal_X.service removal
ansible.builtin.service:
daemon_reload : true
when : "matrix_mautrix_signal_service_stat.stat.exists or matrix_mautrix_signal_daemon_service_stat.stat.exists"