[unbound] wtf

main
_shirenn 2022-11-20 20:13:05 +01:00
parent 4fc73176d8
commit 052519e85e
3 changed files with 39 additions and 36 deletions

View File

@ -1,6 +1,11 @@
--- ---
- name: Restart unbound - name: systemctl restart unbound.service
systemd: systemd:
name: unbound name: unbound
enabled: true enabled: true
state: restart state: restarted
listen: update root trust anchor
- name: run unbound-anchor
command: unbound-anchor
listen: update root trust anchor

View File

@ -11,12 +11,9 @@
- name: Download the root file - name: Download the root file
get_url: get_url:
url: https://www.internic.net/domain/named.root url: https://www.internic.net/domain/named.root
dest: /var/unbound/etc/root.hints dest: /etc/unbound/root.hints
mode: "0444" mode: "0644"
notify: Reload unbound notify: update root trust anchor
- name: Fetch the initial keys
command: unbound-anchor
- name: Deploy the configuration - name: Deploy the configuration
template: template:
@ -25,7 +22,7 @@
owner: root owner: root
group: root group: root
mode: 0644 mode: 0644
notify: Reload unbound notify: systemctl restart unbound.service
- name: Enable and start unbound - name: Enable and start unbound
systemd: systemd:

View File

@ -12,12 +12,13 @@ server:
{% endfor %} {% endfor %}
{% endfor %} {% endfor %}
# reply on the same interface that the query came from
interface-automatic: yes
# chroot: "/etc/unbound" # chroot: "/etc/unbound"
# username: "unbound" # username: "unbound"
# directory: "/etc/unbound" # directory: "/etc/unbound"
num-threads: 8
# the log file, "" means log to stderr. # the log file, "" means log to stderr.
# Use of this option sets use-syslog to "no". # Use of this option sets use-syslog to "no".
# logfile: "" # logfile: ""