summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xcreate.py2
-rw-r--r--group_vars/labdns.yml26
-rw-r--r--playbooks/roles/labdns/templates/volumes/unbound/a-records.conf2
-rw-r--r--playbooks/roles/labdns/templates/volumes/unbound/forward-records.conf7
4 files changed, 19 insertions, 18 deletions
diff --git a/create.py b/create.py
index 01dcaef..a9d81a5 100755
--- a/create.py
+++ b/create.py
@@ -94,7 +94,7 @@ class HomelabDns:
return False
new_lines = (
lines[0:internal_services + 1]
- + [f" - {dns_prefix}\n"]
+ + [f" - {dns_prefix}.{{{{ domain }}}}\n"]
+ lines[internal_services + 1:]
)
if not new_lines:
diff --git a/group_vars/labdns.yml b/group_vars/labdns.yml
index 5ec022c..70fd718 100644
--- a/group_vars/labdns.yml
+++ b/group_vars/labdns.yml
@@ -3,16 +3,16 @@
labdns_base: "{{ swarm_base }}/labdns"
internal_services:
- - test
- - bin
- - ci
- - idm
- - kanban
- - loadbalancer
- - notes
- - passwd
- - pihole
- - proxy
- - src
- - swarm
- - traefik
+ - test.{{ domain }}
+ - bin.{{ domain }}
+ - ci.{{ domain }}
+ - idm.{{ domain }}
+ - kanban.{{ domain }}
+ - loadbalancer.{{ domain }}
+ - notes.{{ domain }}
+ - passwd.{{ domain }}
+ - pihole.{{ domain }}
+ - proxy.{{ domain }}
+ - src.{{ domain }}
+ - swarm.{{ domain }}
+ - traefik.{{ domain }}
diff --git a/playbooks/roles/labdns/templates/volumes/unbound/a-records.conf b/playbooks/roles/labdns/templates/volumes/unbound/a-records.conf
index 9462aab..6248b0c 100644
--- a/playbooks/roles/labdns/templates/volumes/unbound/a-records.conf
+++ b/playbooks/roles/labdns/templates/volumes/unbound/a-records.conf
@@ -1,4 +1,4 @@
# {{ domain }}
{% for service in internal_services %}
-local-data: "{{ service }}.{{ domain }}. A {{ loadbalancer_ip }}"
+local-data: "{{ service }}. A {{ loadbalancer_ip }}"
{% endfor %}
diff --git a/playbooks/roles/labdns/templates/volumes/unbound/forward-records.conf b/playbooks/roles/labdns/templates/volumes/unbound/forward-records.conf
index 19af327..ae977e7 100644
--- a/playbooks/roles/labdns/templates/volumes/unbound/forward-records.conf
+++ b/playbooks/roles/labdns/templates/volumes/unbound/forward-records.conf
@@ -1,5 +1,6 @@
forward-zone:
name: "."
- forward-addr: 1.1.1.1@853#cloudflare-dns.com
- forward-addr: 1.0.0.1@853#cloudflare-dns.com
- forward-tls-upstream: yes
+ forward-addr: 10.128.0.44@53
+# forward-addr: 1.1.1.1@853#cloudflare-dns.com
+# forward-addr: 1.0.0.1@853#cloudflare-dns.com
+# forward-tls-upstream: yes