cri-o reset all containers and pods (#3856)
Signed-off-by: Ganesh Maharaj Mahalingam <ganesh.mahalingam@intel.com>pull/3889/head
parent
e50647d252
commit
1a50a1a733
|
@ -67,6 +67,17 @@
|
|||
tags:
|
||||
- docker
|
||||
|
||||
- name: reset | stop all cri-o containers
|
||||
shell: "crictl ps -aq | xargs -r crictl stop"
|
||||
register: remove_all_crio_containers
|
||||
retries: 4
|
||||
until: remove_all_crio_containers.rc == 0
|
||||
delay: 5
|
||||
tags:
|
||||
- crio
|
||||
when: container_manager == 'crio'
|
||||
|
||||
|
||||
- name: reset | remove all cri-o containers
|
||||
shell: "crictl ps -aq | xargs -r crictl rm"
|
||||
register: remove_all_crio_containers
|
||||
|
@ -77,6 +88,25 @@
|
|||
- crio
|
||||
when: container_manager == 'crio' and deploy_container_engine|default(true)
|
||||
|
||||
- name: reset | stop all cri-o pods
|
||||
shell: "crictl pods -q | xargs -r crictl stopp"
|
||||
register: remove_all_crio_containers
|
||||
retries: 4
|
||||
until: remove_all_crio_containers.rc == 0
|
||||
delay: 5
|
||||
tags:
|
||||
- crio
|
||||
when: container_manager == 'crio'
|
||||
|
||||
- name: reset | remove all cri-o pods
|
||||
shell: "crictl pods -q | xargs -r crictl rmp"
|
||||
register: remove_all_crio_containers
|
||||
retries: 4
|
||||
until: remove_all_crio_containers.rc == 0
|
||||
delay: 5
|
||||
tags:
|
||||
- crio
|
||||
when: container_manager == 'crio'
|
||||
- name: reset | gather mounted kubelet dirs
|
||||
shell: mount | grep /var/lib/kubelet/ | awk '{print $3}' | tac
|
||||
args:
|
||||
|
|
Loading…
Reference in New Issue