-
Notifications
You must be signed in to change notification settings - Fork 24
/
Copy pathhub.j2
39 lines (39 loc) · 1.01 KB
/
hub.j2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
!
router ospf 1
router-id 10.0.0.{{ id }}
!
interface Loopback0
ip ospf 1 area 0.0.0.0
!
interface GigabitEthernet0/1
ip ospf network point-to-point
ip ospf 1 area 0.0.0.0
!
{% for intf in interfaces if intf.type is defined and intf.type == "tunnel" %}
interface {{ intf.ifname }}
description DMVPN Tunnel
ip address {{ intf.ipv4|ipaddr('address') }} {{ intf.ipv4|ipaddr('netmask') }}
no ip redirects
ip mtu 1400
ip nhrp authentication {{ dmvpn.nhrp_keys[inventory_hostname] }}
ip nhrp map multicast dynamic
ip nhrp network-id {{ id }}
ip tcp adjust-mss 1360
ip ospf network point-to-multipoint
ip ospf 1 area 0.0.0.0
load-interval 30
keepalive 5 10
tunnel source GigabitEthernet0/1
tunnel mode gre multipoint
tunnel path-mtu-discovery
{% endfor%}
!
{% for intf in interfaces if intf.type is defined and intf.type == "lan" %}
{% for n in intf.neighbors %}
{% if n.node == "firewall" %}
ip route 0.0.0.0 0.0.0.0 {{ n.ipv4|ipaddr('address') }} name default_to_firewall
{% endif %}
{% endfor%}
{% endfor%}
!
an