system-config/playbooks/roles/unbound/tasks/main.yaml
James E. Blair c6b22d7e13 unbound: fix dhclient.conf copy
The original version of this was wishful thinking: "is file" only
works locally, but this needs to run on the remote node.

Change-Id: Ib683809fdf580f41d213308331925c4765bb09d9
2018-08-28 14:28:48 -07:00

31 lines
588 B
YAML

- name: Include OS-specific tasks
include_tasks: "{{ item }}"
vars:
params:
files: "{{ distro_lookup_path }}"
skip: true
loop: "{{ query('first_found', params) }}"
- name: Install unbound
package:
state: present
name: unbound
- name: Write dhclient config files
include_tasks: dhclient.yaml
loop:
- /etc/dhcp/dhclient.conf
- /etc/dhcp/dhclient-eth0.conf
- name: Write resolv.conf
copy:
src: resolv.conf
dest: /etc/resolv.conf
mode: 0444
- name: Enable unbound
service:
name: unbound
enabled: true
state: started