Skip to content

Commit

Permalink
Config tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
sbyrnes committed Jan 31, 2025
1 parent 2f834f1 commit a89344e
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 10 deletions.
13 changes: 10 additions & 3 deletions internal-lab-setup-assets/startup-config/cisco1.conf
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ call-home
cdp
lldp
!
interface MgmtEth0/RP0/CPU0/0
{{ if .Env.CLAB_MGMT_VRF }} vrf {{ .Env.CLAB_MGMT_VRF }}{{end}}
!
interface Loopback0
ip address 198.51.100.1 255.255.255.255
!
Expand Down Expand Up @@ -61,13 +64,17 @@ route-policy PERMIT_ALL
end-policy
!
router static
{{ if .Env.CLAB_MGMT_VRF }} vrf {{ .Env.CLAB_MGMT_VRF }}{{end}}
{{- if .MgmtIPv4Gateway }}
address-family ipv4 unicast
0.0.0.0/0 MgmtEth0/RP0/CPU0/0 {{ .MgmtIPv4Gateway }}
!
!
{{- end}}
{{- if .MgmtIPv6Gateway }}
address-family ipv6 unicast
::/0 MgmtEth0/RP0/CPU0/0 {{ .MgmtIPv6Gateway }}
!
!
!
{{- end}}
router bgp 64500
bgp router-id 198.51.100.1
address-family ipv4 unicast
Expand Down
12 changes: 10 additions & 2 deletions internal-lab-setup-assets/startup-config/cisco2.conf
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ call-home
cdp
lldp
!
interface MgmtEth0/RP0/CPU0/0
{{ if .Env.CLAB_MGMT_VRF }} vrf {{ .Env.CLAB_MGMT_VRF }}{{end}}
!
interface Loopback0
ip address 198.51.100.2 255.255.255.255
!
Expand Down Expand Up @@ -61,12 +64,17 @@ route-policy PERMIT_ALL
end-policy
!
router static
{{ if .Env.CLAB_MGMT_VRF }} vrf {{ .Env.CLAB_MGMT_VRF }}{{end}}
{{- if .MgmtIPv4Gateway }}
address-family ipv4 unicast
0.0.0.0/0 MgmtEth0/RP0/CPU0/0 {{ .MgmtIPv4Gateway }}
!
!
{{- end}}
{{- if .MgmtIPv6Gateway }}
address-family ipv6 unicast
::/0 MgmtEth0/RP0/CPU0/0 {{ .MgmtIPv6Gateway }}
!
!
{{- end}}
!
router bgp 64500
bgp router-id 198.51.100.2
Expand Down
12 changes: 10 additions & 2 deletions internal-lab-setup-assets/startup-config/cisco3.conf
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ call-home
cdp
lldp
!
interface MgmtEth0/RP0/CPU0/0
{{ if .Env.CLAB_MGMT_VRF }} vrf {{ .Env.CLAB_MGMT_VRF }}{{end}}
!
interface Loopback0
ip address 198.51.100.3 255.255.255.255
!
Expand All @@ -51,12 +54,17 @@ route-policy PERMIT_ALL
end-policy
!
router static
{{ if .Env.CLAB_MGMT_VRF }} vrf {{ .Env.CLAB_MGMT_VRF }}{{end}}
{{- if .MgmtIPv4Gateway }}
address-family ipv4 unicast
0.0.0.0/0 MgmtEth0/RP0/CPU0/0 {{ .MgmtIPv4Gateway }}
!
!
{{- end}}
{{- if .MgmtIPv6Gateway }}
address-family ipv6 unicast
::/0 MgmtEth0/RP0/CPU0/0 {{ .MgmtIPv6Gateway }}
!
!
{{- end}}
!
router bgp 64500
bgp router-id 198.51.100.3
Expand Down
6 changes: 3 additions & 3 deletions internal-lab-setup-assets/workshop.clab.yml.j2
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{%- set id = id|default(1) %}
{%- macro shared_node_settings(x) %}
mgmt-ipv4: 172.16.{{id}}.{{x}}
mgmt-ipv6: 2001:db8:16:{{id}}::{{x}}
ports:
- 2{{"%02d" % id}}{{x}}:22
env:
CLAB_MGMT_VRF: management
{%- endmacro -%}
name: automation-workshop-{{"%02d" % id}}

mgmt:
network: automation-workshop-{{"%02d" % id}}
ipv4-subnet: 172.16.{{id}}.0/24
ipv6-subnet: 2001:db8:16:{{id}}::/80

topology:
kinds:
Expand Down Expand Up @@ -39,7 +39,7 @@ topology:
image: internet2/getting_started
{{- shared_node_settings(x) }}
env:
LAB_PASSWORD: Ninja-{{"%02d" % id}}-Turtles
LAB_PASSWORD: Ninja-{{"%02d" % id}}-Turtle

links:
- endpoints: ["cisco1:Gi0-0-0-0", "cisco3:Gi0-0-0-0"]
Expand Down

0 comments on commit a89344e

Please sign in to comment.