36 lines
732 B
YAML
36 lines
732 B
YAML
---
|
|
|
|
- name: Install packages for local resolver
|
|
tags: resolver-install
|
|
ansible.builtin.package:
|
|
name:
|
|
- nsd
|
|
- git
|
|
state: latest
|
|
|
|
- name: NSD - Enable service
|
|
tags: nsd-enable
|
|
ansible.builtin.service:
|
|
name: 'nsd'
|
|
state: started
|
|
enabled: yes
|
|
|
|
- name: NSD - Define configuration
|
|
tags: nsd-configure
|
|
ansible.builtin.template:
|
|
src: nsd.conf
|
|
dest: /etc/nsd/nsd.conf
|
|
validate: /usr/sbin/nsd-checkconf %s
|
|
backup: yes
|
|
notify: restart nsd
|
|
|
|
- name: Auto-update the git repo for the internal zone
|
|
tags: nsd-dns-gitupdate
|
|
ansible.builtin.git:
|
|
repo: https://git.labolyon.fr/LOL-si/dns-lolinternal.git
|
|
dest: /srv/nsd/
|
|
version: main
|
|
update: yes
|
|
notify:
|
|
- restart nsd
|