initial pfannkuchen

This commit is contained in:
sascha 2026-03-30 15:19:20 +02:00
parent b6dafc7a73
commit 4d305fa19f
99 changed files with 3575 additions and 321 deletions

View file

@ -0,0 +1,6 @@
---
pihole_dns_domain: local
pihole_custom_list: /etc/pihole/custom.list
pihole_extra_records: []
# - ip: 10.4.1.120
# name: authentik

View file

@ -0,0 +1,4 @@
---
- name: Reload Pi-hole DNS
ansible.builtin.command: pihole restartdns reload
listen: reload pihole dns

View file

@ -0,0 +1,9 @@
---
- name: Deploy Pi-hole custom DNS records
ansible.builtin.template:
src: custom.list.j2
dest: "{{ pihole_custom_list }}"
owner: root
group: root
mode: "0644"
notify: reload pihole dns

View file

@ -0,0 +1,11 @@
# Von Ansible generiert nicht manuell bearbeiten
{% for host in groups['all'] %}
{% if hostvars[host].ansible_host is defined %}
{{ hostvars[host].ansible_host }} {{ host }}.{{ pihole_dns_domain }}
{{ hostvars[host].ansible_host }} {{ host }}
{% endif %}
{% endfor %}
{% for entry in pihole_extra_records %}
{{ entry.ip }} {{ entry.name }}.{{ pihole_dns_domain }}
{{ entry.ip }} {{ entry.name }}
{% endfor %}