refact(e2e): load key's passphrase in dataset after node-power-failure test case

Signed-off-by: w3aman <aman.gupta@mayadata.io>
This commit is contained in:
w3aman 2021-07-27 16:31:51 +05:30
parent c0653530bd
commit 96ae41c094
4 changed files with 60 additions and 3 deletions

View file

@ -25,12 +25,29 @@
- block:
- name: stop the {{ svc_type }} service on node where application pod is scheduled
- name: stop the docker service on node where application pod is scheduled
shell: >
sshpass -p {{ node_pwd }} ssh -o StrictHostKeyChecking=no {{ user }}@{{ node_ip_add }}
"echo {{ node_pwd }} | sudo -S su -c 'systemctl stop {{ svc_type }}.service'"
"echo {{ node_pwd }} | sudo -S su -c 'systemctl stop docker.socket'"
args:
executable: /bin/bash
when: svc_type == "docker"
- name: stop the container runtime (if containerd, or crio) services on the application node
shell: >
sshpass -p {{ node_pwd }} ssh -o StrictHostKeyChecking=no {{ user }}@{{ node_ip_add }}
"echo {{ node_pwd }} | sudo -S su -c 'systemctl stop {{ svc_type }}.service'"
args:
executable: /bin/bash
when: svc_type == "containerd" or svc_type == "crio"
- name: stop the kubelet service on node where application pod is scheduled
shell: >
sshpass -p {{ node_pwd }} ssh -o StrictHostKeyChecking=no {{ user }}@{{ node_ip_add }}
"echo {{ node_pwd }} | sudo -S su -c 'systemctl stop kubelet.service'"
args:
executable: /bin/bash
when: svc_type == "kubelet"
- name: Check for the {{ svc_type }} service status
shell: >
@ -91,12 +108,29 @@
- block:
- name: Start the {{ svc_type }} services
- name: Start the docker services
shell: >
sshpass -p {{ node_pwd }} ssh -o StrictHostKeyChecking=no {{ user }}@{{ node_ip_add }}
"echo {{ node_pwd }} | sudo -S su -c 'systemctl start docker.socket'"
args:
executable: /bin/bash
when: svc_type == "docker"
- name: Start the container runtime (if containerd, or crio) services
shell: >
sshpass -p {{ node_pwd }} ssh -o StrictHostKeyChecking=no {{ user }}@{{ node_ip_add }}
"echo {{ node_pwd }} | sudo -S su -c 'systemctl start {{ svc_type }}.service'"
args:
executable: /bin/bash
when: svc_type == "containerd" or svc_type == "crio"
- name: Start the kubelet services
shell: >
sshpass -p {{ node_pwd }} ssh -o StrictHostKeyChecking=no {{ user }}@{{ node_ip_add }}
"echo {{ node_pwd }} | sudo -S su -c 'systemctl start kubelet.service'"
args:
executable: /bin/bash
when: svc_type == "kubelet"
- name: Check for the {{ svc_type }} services status
shell: >