init
This commit is contained in:
commit
1e1c911e13
1 changed files with 20 additions and 0 deletions
20
tasks/main.yml
Normal file
20
tasks/main.yml
Normal file
|
@ -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:
|
Loading…
Reference in a new issue