26 lines
825 B
YAML
26 lines
825 B
YAML
|
---
|
||
|
|
||
|
- name: Check existence of Roundcube systemd service
|
||
|
ansible.builtin.stat:
|
||
|
path: "{{ devture_systemd_docker_base_systemd_path }}/{{ roundcube_identifier }}.service"
|
||
|
register: roundcube_service_stat
|
||
|
|
||
|
- when: roundcube_service_stat.stat.exists | bool
|
||
|
block:
|
||
|
- name: Ensure Roundcube systemd service is stopped
|
||
|
ansible.builtin.service:
|
||
|
name: "{{ roundcube_identifier }}"
|
||
|
state: stopped
|
||
|
enabled: false
|
||
|
daemon_reload: true
|
||
|
|
||
|
- name: Ensure Roundcube systemd service does not exist
|
||
|
ansible.builtin.file:
|
||
|
path: "{{ devture_systemd_docker_base_systemd_path }}/{{ roundcube_identifier }}.service"
|
||
|
state: absent
|
||
|
|
||
|
- name: Ensure Roundcube path doesn't exist
|
||
|
ansible.builtin.file:
|
||
|
path: "{{ roundcube_base_path }}"
|
||
|
state: absent
|