From 1e1c911e13e8db61e260b0f2328be3e6525b5d7a Mon Sep 17 00:00:00 2001 From: Pim Kunis Date: Fri, 14 Apr 2023 09:28:34 +0200 Subject: [PATCH] init --- tasks/main.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 tasks/main.yml diff --git a/tasks/main.yml b/tasks/main.yml new file mode 100644 index 0000000..2ac30c8 --- /dev/null +++ b/tasks/main.yml @@ -0,0 +1,20 @@ +--- + +- name: Wait for SSH connection + wait_for: + state: started + port: 22 + host: "{{ ansible_host }}" + timeout: 300 + connect_timeout: 300 + search_regex: OpenSSH + delegate_to: localhost + +- name: Wait for cloud-init to finish + shell: + cmd: "cloud-init status --wait" + register: cloudinit + changed_when: "'.' in cloudinit.stdout" + +- name: Gather facts + setup: