28 lines
649 B
YAML
28 lines
649 B
YAML
---
|
|
- hosts: all
|
|
gather_facts: no
|
|
tasks:
|
|
- name: Wait for cloud init to finish
|
|
pause:
|
|
minutes: 2
|
|
- name: Update repositories
|
|
apt:
|
|
autoremove: true
|
|
upgrade: yes
|
|
state: latest
|
|
update_cache: yes
|
|
cache_valid_time: 86400 # One day
|
|
- name: Disable systemd-resolved
|
|
systemd:
|
|
name: systemd-resolved
|
|
enabled: false
|
|
state: stopped
|
|
- name: Copy dnsmasq configuration
|
|
copy:
|
|
src: "dnsmasq.conf"
|
|
dest: "/etc/dnsmasq.conf"
|
|
- name: Enable dnsmasq
|
|
systemd:
|
|
name: dnsmasq
|
|
enabled: true
|
|
state: started
|