mirror of
https://github.com/trailofbits/algo.git
synced 2025-06-07 15:43:54 +02:00
fix: Use wait_for_connection to avoid failure (#1381)
With preexisting wait_for implementation, deployment to Ubuntu on Lightsail failed with a connection reset error on this task. It appears that Ansible’s wait_for_connection is the recommended way. I have successfully gotten past this task after this change, however I’d appreciate more eyes on this.
This commit is contained in:
parent
5904546a48
commit
368ebc8625
1 changed files with 3 additions and 7 deletions
|
@ -24,16 +24,12 @@
|
||||||
when: reboot_required is defined and reboot_required.stdout == 'required'
|
when: reboot_required is defined and reboot_required.stdout == 'required'
|
||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
|
|
||||||
- name: Wait until SSH becomes ready...
|
- name: Wait until the server becomes ready...
|
||||||
wait_for:
|
wait_for_connection:
|
||||||
port: 22
|
delay: 20
|
||||||
host: "{{ inventory_hostname }}"
|
|
||||||
search_regex: OpenSSH
|
|
||||||
delay: 10
|
|
||||||
timeout: 320
|
timeout: 320
|
||||||
when: reboot_required is defined and reboot_required.stdout == 'required'
|
when: reboot_required is defined and reboot_required.stdout == 'required'
|
||||||
become: false
|
become: false
|
||||||
delegate_to: localhost
|
|
||||||
when: algo_provider != "local"
|
when: algo_provider != "local"
|
||||||
|
|
||||||
- name: Include unatteded upgrades configuration
|
- name: Include unatteded upgrades configuration
|
||||||
|
|
Loading…
Add table
Reference in a new issue