diff --git a/src/molecule_plugins/gce/playbooks/tasks/create_linux_instance.yml b/src/molecule_plugins/gce/playbooks/tasks/create_linux_instance.yml index bd705a1..a5efeb3 100644 --- a/src/molecule_plugins/gce/playbooks/tasks/create_linux_instance.yml +++ b/src/molecule_plugins/gce/playbooks/tasks/create_linux_instance.yml @@ -61,6 +61,8 @@ host: "{{ item.networkInterfaces.0.accessConfigs.0.natIP if molecule_yml.driver.external_access else item.networkInterfaces.0.networkIP }}" search_regex: SSH delay: 10 + loop: "{{ server.results }}" + register: waitfor + until: waitfor.failed == false retries: 6 delay: 10 - loop: "{{ server.results }}" diff --git a/src/molecule_plugins/gce/playbooks/tasks/create_windows_instance.yml b/src/molecule_plugins/gce/playbooks/tasks/create_windows_instance.yml index e828409..86e2a20 100644 --- a/src/molecule_plugins/gce/playbooks/tasks/create_windows_instance.yml +++ b/src/molecule_plugins/gce/playbooks/tasks/create_windows_instance.yml @@ -51,6 +51,10 @@ host: "{{ item.networkInterfaces.0.accessConfigs.0.natIP if molecule_yml.driver.external_access else item.networkInterfaces.0.networkIP }}" delay: 10 loop: "{{ server.results }}" + register: waitfor + until: waitfor.failed == false + retries: 6 + delay: 10 - name: Prepare Windows User ansible.builtin.script: >