Files
ansible-playbook/xxxigcc_uninstall.yaml
Wang Defa ecf247ac37 添加
2025-12-05 20:49:32 +08:00

30 lines
756 B
YAML

---
- name: XXXigCC 卸载脚本
hosts: all
become: yes
tasks:
- name: 下载卸载脚本
ansible.builtin.get_url:
url: https://gitea.bcde.io/wangdefa/xxxigcc/raw/branch/main/script/uninstall.sh
dest: /tmp/uninstall.sh
mode: '0755'
force: yes
validate_certs: yes
register: download_result
- name: 执行卸载脚本
ansible.builtin.shell: /tmp/uninstall.sh
args:
executable: /bin/bash
register: script_output
changed_when: true
- name: 显示脚本执行结果
ansible.builtin.debug:
var: script_output.stdout_lines
- name: 清理临时脚本文件
ansible.builtin.file:
path: /tmp/uninstall.sh
state: absent