From 000a5c1501da6575460d96b47e8918a359ff0b49 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Sun, 31 May 2020 04:11:07 +0200 Subject: cloud-install: add ubuntu/focal support --- common/cloud-install.yml | 8 ++++++++ common/vm-install.yml | 7 +++++++ 2 files changed, 15 insertions(+) (limited to 'common') diff --git a/common/cloud-install.yml b/common/cloud-install.yml index 414cabd1..875d2880 100644 --- a/common/cloud-install.yml +++ b/common/cloud-install.yml @@ -5,6 +5,7 @@ roles: - role: cloud/install + - name: wait for newly installed machine to start up hosts: "{{ install_hostname }}" gather_facts: no @@ -13,14 +14,20 @@ - name: disable ssh StrictHostKeyChecking for the next step set_fact: ansible_ssh_extra_args: -o StrictHostKeyChecking=no + + - name: clear all gathered facts + meta: clear_facts + - name: wait for newly installed machine to start up wait_for_connection: delay: 5 timeout: 120 + - name: reenable StrictHostKeyChecking set_fact: ansible_ssh_extra_args: "" + - name: run post install roles hosts: "{{ install_hostname }}" pre_tasks: @@ -29,6 +36,7 @@ roles: - role: cloud/post-install + - name: reboot and wait for machine come back hosts: "{{ install_hostname }}" gather_facts: no diff --git a/common/vm-install.yml b/common/vm-install.yml index 7aaf32fc..f90d0cd0 100644 --- a/common/vm-install.yml +++ b/common/vm-install.yml @@ -29,6 +29,7 @@ roles: - role: vm/install + - name: wait for new vm to start up hosts: "{{ install_hostname }}" gather_facts: no @@ -37,14 +38,20 @@ - name: disable ssh StrictHostKeyChecking for the next step set_fact: ansible_ssh_extra_args: -o StrictHostKeyChecking=no + + - name: clear all gathered facts + meta: clear_facts + - name: wait for vm to start up wait_for_connection: delay: 5 timeout: 120 + - name: reenable StrictHostKeyChecking set_fact: ansible_ssh_extra_args: "" + - name: apply basic VM configuration roles hosts: "{{ install_hostname }}" pre_tasks: -- cgit v1.2.3