feat: added alpine support
This commit is contained in:
parent
424de33046
commit
e475d2ce40
4 changed files with 25 additions and 4 deletions
|
|
@ -1,9 +1,18 @@
|
|||
---
|
||||
|
||||
# unbound
|
||||
- name: "restart unbound"
|
||||
- name: "restart unbound debian"
|
||||
ansible.builtin.systemd:
|
||||
name: "unbound.service"
|
||||
state: "restarted"
|
||||
daemon_reload: true
|
||||
enabled: true
|
||||
when: ansible_os_family == "Debian"
|
||||
listen: "restart unbound"
|
||||
|
||||
- name: "restart unbound alpine"
|
||||
ansible.builtin.service:
|
||||
name: "unbound"
|
||||
state: "restarted"
|
||||
when: ansible_os_family == "Alpine"
|
||||
listen: "restart unbound"
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ This role configures an Unbound DNS server.
|
|||
|
||||
| Operating System | Version |
|
||||
| --- | ----- |
|
||||
| Alpine | 3.22 |
|
||||
| Debian | 12 |
|
||||
|
||||
## Tags
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
|
||||
# configure unbound
|
||||
# confiure unbound
|
||||
- name: "config - unbound"
|
||||
ansible.builtin.template:
|
||||
src: "templates/unbound/unbound.conf.j2"
|
||||
|
|
@ -8,7 +8,9 @@
|
|||
owner: "root"
|
||||
group: "root"
|
||||
mode: "0644"
|
||||
notify: "restart unbound"
|
||||
notify:
|
||||
- "restart unbound debian"
|
||||
- "restart unbound alpine"
|
||||
|
||||
# configure unbound zones
|
||||
- name: "config - unbound zones"
|
||||
|
|
@ -18,4 +20,6 @@
|
|||
owner: "root"
|
||||
group: "root"
|
||||
mode: "0644"
|
||||
notify: "restart unbound"
|
||||
notify:
|
||||
- "restart unbound debian"
|
||||
- "restart unbound alpine"
|
||||
|
|
|
|||
|
|
@ -6,3 +6,10 @@
|
|||
name: "unbound"
|
||||
cache_valid_time: 120
|
||||
when: 'ansible_os_family == "Debian"'
|
||||
|
||||
# install unbound
|
||||
- name: "install unbound"
|
||||
community.general.apk:
|
||||
name: "unbound"
|
||||
update_cache: true
|
||||
when: 'ansible_os_family == "Alpine"'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue