Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions ansible/roles/eos/templates/t0-64-32-leaf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
{% set mgmt_ip = ansible_host %}
hostname {{ hostname }}
!
vrf definition MGMT
rd 1:1
!
spanning-tree mode mstp
!
aaa root secret 0 123456
Expand All @@ -12,13 +15,16 @@ clock timezone UTC
!
lldp run
lldp management-address Management1
lldp management-address vrf MGMT
!
snmp-server community {{ snmp_rocommunity }} ro
snmp-server vrf MGMT
!
ip routing
ip routing vrf MGMT
ipv6 unicast-routing
!
ip route 0.0.0.0/0 {{ mgmt_gw }}
ip route vrf MGMT 0.0.0.0/0 {{ mgmt_gw }}
!
route-map DEFAULT_ROUTES permit
!
Expand Down Expand Up @@ -62,6 +68,7 @@ exit
!
interface Management 1
description TO LAB MGMT SWITCH
vrf forwarding MGMT
ip address {{ mgmt_ip }}/{{ mgmt_prefixlen }}
no shutdown
!
Expand All @@ -77,7 +84,7 @@ interface {{ name }}
{% endif %}
{% if iface['lacp'] is defined %}
channel-group {{ iface['lacp'] }} mode active
lacp rate fast
lacp rate normal
{% endif %}
{% if iface['ipv4'] is defined %}
ip address {{ iface['ipv4'] }}
Expand Down Expand Up @@ -148,5 +155,3 @@ management api http-commands
no shutdown
!
end


12 changes: 9 additions & 3 deletions ansible/roles/eos/templates/t0-64-leaf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
{% set mgmt_ip = ansible_host %}
hostname {{ hostname }}
!
vrf definition MGMT
rd 1:1
!
spanning-tree mode mstp
!
aaa root secret 0 123456
Expand All @@ -12,13 +15,16 @@ clock timezone UTC
!
lldp run
lldp management-address Management1
lldp management-address vrf MGMT
!
snmp-server community {{ snmp_rocommunity }} ro
snmp-server vrf MGMT
!
ip routing
ip routing vrf MGMT
ipv6 unicast-routing
!
ip route 0.0.0.0/0 {{ mgmt_gw }}
ip route vrf MGMT 0.0.0.0/0 {{ mgmt_gw }}
!
route-map DEFAULT_ROUTES permit
!
Expand Down Expand Up @@ -62,6 +68,7 @@ exit
!
interface Management 1
description TO LAB MGMT SWITCH
vrf forwarding MGMT
ip address {{ mgmt_ip }}/{{ mgmt_prefixlen }}
no shutdown
!
Expand All @@ -77,7 +84,7 @@ interface {{ name }}
{% endif %}
{% if iface['lacp'] is defined %}
channel-group {{ iface['lacp'] }} mode active
lacp rate fast
lacp rate normal
{% endif %}
{% if iface['ipv4'] is defined %}
ip address {{ iface['ipv4'] }}
Expand Down Expand Up @@ -148,4 +155,3 @@ management api http-commands
no shutdown
!
end

12 changes: 9 additions & 3 deletions ansible/roles/eos/templates/t0-leaf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
{% set mgmt_ip = ansible_host %}
hostname {{ hostname }}
!
vrf definition MGMT
rd 1:1
!
spanning-tree mode mstp
!
aaa root secret 0 123456
Expand All @@ -12,13 +15,16 @@ clock timezone UTC
!
lldp run
lldp management-address Management1
lldp management-address vrf MGMT
!
snmp-server community {{ snmp_rocommunity }} ro
snmp-server vrf MGMT
!
ip routing
ip routing vrf MGMT
ipv6 unicast-routing
!
ip route 0.0.0.0/0 {{ mgmt_gw }}
ip route vrf MGMT 0.0.0.0/0 {{ mgmt_gw }}
!
route-map DEFAULT_ROUTES permit
!
Expand Down Expand Up @@ -62,6 +68,7 @@ exit
!
interface Management 1
description TO LAB MGMT SWITCH
vrf forwarding MGMT
ip address {{ mgmt_ip }}/{{ mgmt_prefixlen }}
no shutdown
!
Expand All @@ -77,7 +84,7 @@ interface {{ name }}
{% endif %}
{% if iface['lacp'] is defined %}
channel-group {{ iface['lacp'] }} mode active
lacp rate fast
lacp rate normal
{% endif %}
{% if iface['ipv4'] is defined %}
ip address {{ iface['ipv4'] }}
Expand Down Expand Up @@ -148,4 +155,3 @@ management api http-commands
no shutdown
!
end

9 changes: 8 additions & 1 deletion ansible/roles/eos/templates/t1-lag-spine.j2
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
{% set mgmt_ip = ansible_host %}
hostname {{ hostname }}
!
vrf definition MGMT
rd 1:1
!
spanning-tree mode mstp
!
aaa root secret 0 123456
Expand All @@ -12,13 +15,16 @@ clock timezone UTC
!
lldp run
lldp management-address Management1
lldp management-address vrf MGMT
!
snmp-server community {{ snmp_rocommunity }} ro
snmp-server vrf MGMT
!
ip routing
ip routing vrf MGMT
ipv6 unicast-routing
!
ip route 0.0.0.0/0 {{ mgmt_gw }}
ip route vrf MGMT 0.0.0.0/0 {{ mgmt_gw }}
!
route-map DEFAULT_ROUTES permit
!
Expand All @@ -42,6 +48,7 @@ exit
!
interface Management 1
description TO LAB MGMT SWITCH
vrf forwarding MGMT
ip address {{ mgmt_ip }}/{{ mgmt_prefixlen }}
no shutdown
!
Expand Down
9 changes: 8 additions & 1 deletion ansible/roles/eos/templates/t1-lag-tor.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
{% set tornum = host['tornum'] %}
hostname {{ hostname }}
!
vrf definition MGMT
rd 1:1
!
spanning-tree mode mstp
!
aaa root secret 0 123456
Expand All @@ -13,13 +16,16 @@ clock timezone UTC
!
lldp run
lldp management-address Management1
lldp management-address vrf MGMT
!
snmp-server community {{ snmp_rocommunity }} ro
snmp-server vrf MGMT
!
ip routing
ip routing vrf MGMT
ipv6 unicast-routing
!
ip route 0.0.0.0/0 {{ mgmt_gw }}
ip route vrf MGMT 0.0.0.0/0 {{ mgmt_gw }}
!
{% for subnet in range(0, props.tor_subnet_number) %}
ip route 172.16.{{ tornum }}.{{ subnet }}/32 {{ props.nhipv4 }}
Expand All @@ -28,6 +34,7 @@ ipv6 route 20AC:10{{ '%02X' % tornum }}:0:{{ '%02X' % subnet }}::/64 {{ props.nh
!
interface Management 1
description TO LAB MGMT SWITCH
vrf forwarding MGMT
ip address {{ mgmt_ip }}/{{ mgmt_prefixlen }}
no shutdown
!
Expand Down
9 changes: 8 additions & 1 deletion ansible/roles/eos/templates/t1-spine.j2
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
{% set mgmt_ip = ansible_host %}
hostname {{ hostname }}
!
vrf definition MGMT
rd 1:1
!
spanning-tree mode mstp
!
aaa root secret 0 123456
Expand All @@ -12,13 +15,16 @@ clock timezone UTC
!
lldp run
lldp management-address Management1
lldp management-address vrf MGMT
!
snmp-server community {{ snmp_rocommunity }} ro
snmp-server vrf MGMT
!
ip routing
ip routing vrf MGMT
ipv6 unicast-routing
!
ip route 0.0.0.0/0 {{ mgmt_gw }}
ip route vrf MGMT 0.0.0.0/0 {{ mgmt_gw }}
!
route-map DEFAULT_ROUTES permit
!
Expand All @@ -42,6 +48,7 @@ exit
!
interface Management 1
description TO LAB MGMT SWITCH
vrf forwarding MGMT
ip address {{ mgmt_ip }}/{{ mgmt_prefixlen }}
no shutdown
!
Expand Down
9 changes: 8 additions & 1 deletion ansible/roles/eos/templates/t1-tor.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
{% set tornum = host['tornum'] %}
hostname {{ hostname }}
!
vrf definition MGMT
rd 1:1
!
spanning-tree mode mstp
!
aaa root secret 0 123456
Expand All @@ -13,13 +16,16 @@ clock timezone UTC
!
lldp run
lldp management-address Management1
lldp management-address vrf MGMT
!
snmp-server community {{ snmp_rocommunity }} ro
snmp-server vrf MGMT
!
ip routing
ip routing vrf MGMT
ipv6 unicast-routing
!
ip route 0.0.0.0/0 {{ mgmt_gw }}
ip route vrf MGMT 0.0.0.0/0 {{ mgmt_gw }}
!
{% for subnet in range(0, props.tor_subnet_number) %}
ip route 172.16.{{ tornum }}.{{ subnet }}/32 {{ props.nhipv4 }}
Expand All @@ -28,6 +34,7 @@ ipv6 route 20AC:10{{ '%02X' % tornum }}:0:{{ '%02X' % subnet }}::/64 {{ props.nh
!
interface Management 1
description TO LAB MGMT SWITCH
vrf forwarding MGMT
ip address {{ mgmt_ip }}/{{ mgmt_prefixlen }}
no shutdown
!
Expand Down
Loading