You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 lines
964 B

  1. ---
  2. - name: Containerd | Remove containerd repository for RedHat os family
  3. file:
  4. path: "{{ yum_repo_dir }}/containerd.repo"
  5. state: absent
  6. when:
  7. - ansible_os_family in ['RedHat']
  8. tags:
  9. - reset_containerd
  10. - name: Containerd | Remove containerd repository for Debian os family
  11. apt_repository:
  12. repo: "{{ item }}"
  13. state: absent
  14. with_items: "{{ containerd_repo_info.repos }}"
  15. when: ansible_pkg_mgr == 'apt'
  16. tags:
  17. - reset_containerd
  18. - name: Containerd | Stop containerd service
  19. service:
  20. name: containerd
  21. daemon_reload: true
  22. enabled: false
  23. state: stopped
  24. tags:
  25. - reset_containerd
  26. - name: Containerd | Remove configuration files
  27. file:
  28. path: "{{ item }}"
  29. state: absent
  30. loop:
  31. - /etc/systemd/system/containerd.service
  32. - "{{ containerd_systemd_dir }}"
  33. - "{{ containerd_cfg_dir }}"
  34. - "{{ containerd_storage_dir }}"
  35. - "{{ containerd_state_dir }}"
  36. tags:
  37. - reset_containerd