fix: add configuration for listen address
continuous-integration/drone/push Build is failing Details

This commit is contained in:
Robert Kaussow 2023-06-21 08:39:53 +02:00
parent 10eefcae1c
commit a6998a80ec
Signed by: xoxys
GPG Key ID: 4E692A2EAECC03C0
5 changed files with 34 additions and 15 deletions

4
defauts/main.yml Normal file
View File

@ -0,0 +1,4 @@
---
dnsmasq_listen_address:
- "127.0.0.1"
- "::1"

9
handlers/main.yml Normal file
View File

@ -0,0 +1,9 @@
- name: Restart dnsmasq Service
service:
name: dnsmasq
state: restarted
daemon_reload: yes
enabled: yes
listen: __dnsmasq_restart
become: True
become_user: root

View File

@ -1,2 +1,21 @@
---
- include_tasks: setup.yml
- block:
- name: Install package
package:
name: dnsmasq
state: present
- name: Create dnsmasq configuration
template:
src: "etc/dnsmasq.d/local.conf.j2"
dest: "/etc/dnsmasq.d/local.conf"
mode: 0644
notify: __dnsmasq_restart
- name: Ensure dnsmasq is up and running
service:
name: dnsmasq
enabled: True
state: started
become: True
become_user: root

View File

@ -1,14 +0,0 @@
---
- block:
- name: Install package
package:
name: dnsmasq
state: present
- name: Ensure dnsmasq is up and running
service:
name: dnsmasq
enabled: True
state: started
become: True
become_user: root

View File

@ -0,0 +1 @@
listen-address={{ dnsmasq_listen_address | join(",") }}