This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
solutions-tsg-scripts/uninstall/roles/uninstall_server/tasks/certstore_after_20.09.yml
zhangzhihan 05b56cb4ec update
2020-09-21 18:33:10 +08:00

43 lines
913 B
YAML

- name: stop certstore
systemd:
name: certstore
state: stopped
enabled: no
when:
- backup.certstore == 1
- uninstall.certstore == 1
ignore_errors: true
- name: create backup_dest_path
file:
path: "{{ backup_dest_path }}"
state: directory
when: backup.certstore == 1
- name: backup /opt/tsg/certstore to destination path
archive:
path: /opt/tsg/certstore
dest: "{{ backup_dest_path }}/certstore_{{ uninstall_version }}_{{ date }}.zip"
format: zip
when: backup.certstore == 1
- name: uninstall certstore
yum:
name:
- "{{ certstore }}"
state: absent
when: uninstall.certstore == 1
- name: remove certstore files
file:
path: /opt/tsg/certstore
state: absent
when: remove.certstore == 1
- name: remove certstore.service
file:
path: /usr/lib/systemd/system/certstore.service
state: absent
when: remove.certstore == 1