Skip to content

Commit

Permalink
test: wait for agent to be ready before verifying snapshot
Browse files Browse the repository at this point in the history
  • Loading branch information
Manuthor committed Jul 10, 2024
1 parent 688ab18 commit 18a0927
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
1 change: 1 addition & 0 deletions ansible/roles/check_app/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
delay: 5
timeout: 60
msg: Timeout waiting for 5555 to respond
delegate_to: localhost

- name: Before anything - read logs of {{ check_app_name }}
ansible.builtin.command:
Expand Down
11 changes: 10 additions & 1 deletion ansible/roles/check_cosmian_vm/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@
- listening
- listening_cosmian_vm

- name: Check Cosmian VM Agent is OK
- name: Check if Cosmian VM Agent is OK
ansible.builtin.uri:
url: https://localhost:5555/ima/ascii
validate_certs: false
Expand Down Expand Up @@ -178,6 +178,15 @@
path: /var/lib/cosmian_vm/data/cert.pem
state: present

- name: Check if port 5555 is listening
ansible.builtin.wait_for:
host: "{{ inventory_hostname }}"
port: 5555
delay: 5
timeout: 60
msg: Timeout waiting for 5555 to respond
delegate_to: localhost

- name: Read current reset count from snapshot
ansible.builtin.shell:
cmd: |
Expand Down

0 comments on commit 18a0927

Please sign in to comment.