improve knot roles reloading behavior
With this change, the nameserver is not restarted on configuration updates but only reloaded instead.
This commit is contained in:
parent
3aa146d723
commit
5283d2da95
2 changed files with 4 additions and 10 deletions
|
|
@ -1,16 +1,10 @@
|
||||||
---
|
---
|
||||||
- name: restart knot
|
- name: reload knot
|
||||||
tags: [ auth-dns ]
|
tags: [ auth-dns ]
|
||||||
become: true
|
become: true
|
||||||
ansible.builtin.systemd:
|
ansible.builtin.systemd:
|
||||||
name: knot.service
|
name: knot.service
|
||||||
state: restarted
|
state: reloaded
|
||||||
|
|
||||||
- name: reload knot zones
|
|
||||||
tags: [ auth-dns ]
|
|
||||||
become: true
|
|
||||||
changed_when: true
|
|
||||||
ansible.builtin.command: "knotc zone-reload"
|
|
||||||
|
|
||||||
- name: netplan apply
|
- name: netplan apply
|
||||||
tags: [ auth-dns ]
|
tags: [ auth-dns ]
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@
|
||||||
- name: Deploy knot configuration file
|
- name: Deploy knot configuration file
|
||||||
tags: [ auth-dns ]
|
tags: [ auth-dns ]
|
||||||
become: true
|
become: true
|
||||||
notify: restart knot
|
notify: reload knot
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: knot.conf.j2
|
src: knot.conf.j2
|
||||||
dest: /etc/knot/knot.conf
|
dest: /etc/knot/knot.conf
|
||||||
|
|
@ -24,7 +24,7 @@
|
||||||
- name: Deploy configured zones
|
- name: Deploy configured zones
|
||||||
tags: [ auth-dns ]
|
tags: [ auth-dns ]
|
||||||
become: true
|
become: true
|
||||||
notify: reload knot zones
|
notify: reload knot
|
||||||
loop: "{{ knot__zones }}"
|
loop: "{{ knot__zones }}"
|
||||||
loop_control:
|
loop_control:
|
||||||
label: "{{ item.domain }}"
|
label: "{{ item.domain }}"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue