forked from FF-RGB/ansible
34 lines
692 B
YAML
34 lines
692 B
YAML
---
|
|
|
|
- name: Install powerdns
|
|
apt:
|
|
name:
|
|
- dnsdist
|
|
- pdns-backend-bind
|
|
- pdns-recursor
|
|
- pdns-server
|
|
|
|
- name: Create zone directory
|
|
file: path=/etc/powerdns/bind/ state=directory
|
|
|
|
- name: Configure powerdns
|
|
template: src={{ item }}.j2 dest=/etc/powerdns/{{ item }}
|
|
notify: Restart powerdns
|
|
with_items:
|
|
- bind/ffrgb.zone
|
|
- bind/90.10.in-addr.arpa.zone
|
|
- bindbackend.conf
|
|
- pdns.conf
|
|
- recursor.conf
|
|
|
|
- name: Configure dnsdist
|
|
template: src=dnsdist.conf.j2 dest=/etc/dnsdist/dnsdist.conf
|
|
notify: Restart dnsdist
|
|
|
|
- name: Start the dns services
|
|
service: name={{ item }} state=started enabled=yes
|
|
with_items:
|
|
- dnsdist
|
|
- pdns
|
|
- pdns-recursor
|