EOX GitLab Instance
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
knot-resolver role
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ansible-public
knot-resolver role
Commits
3b2825fb
Commit
3b2825fb
authored
1 year ago
by
Karl Grube
Browse files
Options
Downloads
Patches
Plain Diff
first working configuration with service vrf
parent
928a962d
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
defaults/main.yml
+2
-1
2 additions, 1 deletion
defaults/main.yml
templates/frr_conf.j2
+15
-8
15 additions, 8 deletions
templates/frr_conf.j2
templates/kresd_conf.j2
+4
-11
4 additions, 11 deletions
templates/kresd_conf.j2
with
21 additions
and
20 deletions
defaults/main.yml
+
2
−
1
View file @
3b2825fb
...
...
@@ -10,4 +10,5 @@ kresd_user: "{% if ansible_os_family == 'Debian' %}knot-resolver{% else %}kresd{
anycast_ips
:
"
{{
dns_anycast_ips
+
dns64_anycast_ips}}"
dns_anycast_ips
:
[]
dns64_anycast_ips
:
[]
dns64_enabled
:
False
This diff is collapsed.
Click to expand it.
templates/frr_conf.j2
+
15
−
8
View file @
3b2825fb
...
...
@@ -27,19 +27,23 @@ router bgp {{bgp_asn}}{% if use_service_vrf == True %} vrf service
{% endif %}
{% endfor %}
address-family ipv4 unicast
redistribute connected route-map service_interfaces
neighbor upstream activate
neighbor upstream prefix-list all in
{% if use_service_vrf == True %}
neighbor upstream route-map service_interfaces out
neighbor upstream prefix-list all out
import vrf default
{% else %}
redistribute connected route-map lo
{% endif %}
!
address-family ipv6 unicast
redistribute connected route-map service_interfaces
neighbor upstream activate
neighbor upstream prefix-list all in
{% if use_service_vrf == True %}
neighbor upstream route-map service_interfaces out
neighbor upstream prefix-list all out
import vrf default
{% else %}
redistribute connected route-map lo
{% endif %}
exit-address-family
exit
...
...
@@ -47,7 +51,10 @@ exit
{% if use_service_vrf == True %}
router bgp {{bgp_asn}}
address-family ipv4 unicast
import vrf service
redistribute connected route-map lo
exit-address-family
address-family ipv6 unicast
redistribute connected route-map lo
exit-address-family
exit
!
...
...
@@ -57,10 +64,10 @@ ip prefix-list all seq 10 permit any
ipv6 prefix-list all seq 10 permit any
ipv6 prefix-list none seq 10 deny any
{% for interface in service_interfaces %}
route-map
service_interfaces
permit {{loop.index*10}}
match interface
{{interface}}
route-map
lo
permit {{loop.index*10}}
match interface
lo
{% if loop.last %}
route-map
service_interfaces permit
{{loop.index*10+10}}
route-map
lo deny
{{loop.index*10+10}}
{% endif %}
exit
{% endfor %}
This diff is collapsed.
Click to expand it.
templates/kresd_conf.j2
+
4
−
11
View file @
3b2825fb
net.listen({ {% for address in dns_anycast_ips + dns64_anycast_ips %}'{{address}}',{% endfor %}'::1','127.0.0.1' }, 53, { freebind = true })
net.listen({'::','0.0.0.0'}, 853, { kind = 'tls' })
--
net.outgoing_v4('{{kresd_outgoing_ipv4}}')
--
net.outgoing_v6('{{kresd_outgoing_ipv6}}')
net.outgoing_v4('{{kresd_outgoing_ipv4}}')
net.outgoing_v6('{{kresd_outgoing_ipv6}}')
user( '{{kresd_user}}','{{kresd_user}}')
-- trust_anchors.file = 'root.keys'
...
...
@@ -20,16 +20,9 @@ modules = {
'stats', -- Track internal statistics
{% endif %}
predict = { window = 15, period = 6*(60/15) },
{% if dns64_enabled == True %}
'dns64', -- use dns64
{% endif %}
--http = { host='localhost', port=8053 },
}
policy.add(
policy.net_match(
{
{% for ip in dns_anycast_ips %}
{ '{{ip}}', policy.FLAGS('DNS64_DISABLE') },
{% endfor %}
}
)
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment