Commit 879099b1 authored by skorpy's avatar skorpy 👷

add fixes to knot-dns

parent 2e06ca7f
Pipeline #24131 passed with stages
in 3 minutes and 16 seconds
......@@ -18,6 +18,7 @@ so we need:
def knot_yaml():
# pylint: disable=undefined-variable
tmp = []
tmp.append('nextnode.ffffm.net:')
for domain in __salt__['pillar.get']('domains'):
global_prefix6 = __salt__['pillar.get'](
'domains:{}:global_prefix6'.format(domain))
......@@ -25,5 +26,7 @@ def knot_yaml():
'domains:{}:nextnode4'.format(domain))
nextnode6 = __salt__['pillar.get'](
'domains:{}:nextnode6'.format(domain))
tmp.extend([{"net": global_prefix6, "A": [nextnode4], "AAAA": [nextnode6]}])
tmp.append(' - net: {}'.format(global_prefix6))
tmp.append(' A: {}'.format(nextnode4))
tmp.append(' AAAA: {}'.format(nextnode6))
return tmp
{# upstream docu: https://www.knot-dns.cz/docs/latest/html/modules.html?highlight=subnet#using-subnets #}
# upstream docu: https://www.knot-dns.cz/docs/latest/html/modules.html?highlight=subnet#using-subnets
nextnode.ffffm.net:
{{ salt['nextnode.knot_yaml']()|yaml(True)| indent(2) }}
{{ salt['nextnode.knot_yaml']() }}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment