This repository has been archived on 2023-12-26. You can view files and clone it, but cannot push or open issues or pull requests.
hermes/ansible/hermes.yml
2023-03-17 17:57:27 +01:00

37 lines
808 B
YAML

---
- hosts: all
gather_facts: no
pre_tasks:
- name: Wait for host to come up
wait_for:
state: started
port: 22
host: "{{ internal_ip }}"
timeout: 300
connect_timeout: 300
search_regex: OpenSSH
delegate_to: localhost
- name: Wait for cloud-init to finish
command:
cmd: cloud-init status --wait
register: cloudinit
changed_when: "'..' in cloudinit.stdout"
- name: Gather facts
setup:
- name: Update repositories
apt:
autoremove: true
upgrade: yes
state: latest
update_cache: yes
cache_valid_time: 86400 # One day
- name: Install packages
apt:
pkg:
- qemu-guest-agent
- dnsutils
roles:
- dnsmasq
- nsd