浏览代码

Add clean cache role

pull/2723/head
Julian-Samuel Gebühr 3 年前
父节点
当前提交
ee187d6fde
共有 2 个文件被更改,包括 10 次插入0 次删除
  1. +4
    -0
      roles/custom/matrix-bot-matrix-registration-bot/tasks/clean_cache.yml
  2. +6
    -0
      roles/custom/matrix-bot-matrix-registration-bot/tasks/main.yml

+ 4
- 0
roles/custom/matrix-bot-matrix-registration-bot/tasks/clean_cache.yml 查看文件

@@ -0,0 +1,4 @@
---

- name: Delete cache files
ansible.builtin.shell: "rm -rf {{ matrix_bot_matrix_registration_bot_data_path }}/*"

+ 6
- 0
roles/custom/matrix-bot-matrix-registration-bot/tasks/main.yml 查看文件

@@ -18,3 +18,9 @@
block:
- when: not matrix_bot_matrix_registration_bot_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_uninstall.yml"

- tags:
- bot-matrix-registration-bot-clean-cache
block:
- when: matrix_bot_matrix_registration_bot_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/clean_cache.yml"

正在加载...
取消
保存