diff --git a/I2_SR_configs.tgz b/I2_SR_configs.tgz new file mode 100644 index 0000000..223e522 Binary files /dev/null and b/I2_SR_configs.tgz differ diff --git a/core-deploy.yml b/core-deploy.yml index 6d06d00..00b15ab 100644 --- a/core-deploy.yml +++ b/core-deploy.yml @@ -47,7 +47,7 @@ - name: Load config (junos) junos_config: src: core_config/{{inventory_hostname}}-config.txt - update: replace + update: override comment: Ansible config update when: ansible_network_os == 'junos' diff --git a/core/core-model-veos.yml b/core/core-model-veos.yml new file mode 100644 index 0000000..fbe9a7d --- /dev/null +++ b/core/core-model-veos.yml @@ -0,0 +1,114 @@ +--- + +common: + bgp_asn: 65000 + +nodes: + - name: ansible-veos1 + mgmt: 10.39.0.41 + rid: 10.39.8.41 + sid: 10 + iso: 49.0001.0010.0100.1001.00 + + - name: ansible-veos2 + mgmt: 10.39.0.42 + rid: 10.39.8.42 + sid: 20 + iso: 49.0001.0010.0100.1002.00 + + - name: ansible-veos3 + mgmt: 10.39.0.43 + rid: 10.39.8.43 + sid: 30 + iso: 49.0001.0010.0100.1003.00 + + - name: ansible-veos4 + mgmt: 10.39.0.44 + rid: 10.39.8.44 + sid: 40 + iso: 49.0001.0010.0100.1004.00 + + - name: ansible-veos5 + mgmt: 10.39.0.55 + rid: 10.39.8.55 + sid: 50 + iso: 49.0001.0010.0100.1005.00 + lu: 163.253.39.165 + + - name: ansible-veos55 + mgmt: 10.39.0.155 + rid: 10.39.8.155 + + - name: ansible-veos6 + mgmt: 10.39.0.56 + rid: 10.39.8.56 + sid: 60 + iso: 49.0001.0010.0100.1006.00 + lu: 163.253.39.165 + + - name: ansible-veos66 + mgmt: 10.39.0.156 + rid: 10.39.8.156 + +links: + - {left: ansible-veos1, left_port: Ethernet1, left_ip: 172.10.12.1, + right: ansible-veos2, right_port: Ethernet1, right_ip: 172.10.12.2, + cost: 10, mpls: True, iso: True } + + - {left: ansible-veos1, left_port: Ethernet2, left_ip: 172.10.13.1, + right: ansible-veos3, right_port: Ethernet1, right_ip: 172.10.13.3, + cost: 10, mpls: True, iso: True } + +# - {left: ansible-veos1, left_port: Ethernet3, left_ip: 172.10.14.1, +# right: ansible-veos4, right_port: Ethernet1, right_ip: 172.10.14.4, +# cost: 10, mpls: True, iso: True } + + - {left: ansible-veos1, left_port: Ethernet4, left_ip: 172.10.15.1, + right: ansible-veos5, right_port: Ethernet1, right_ip: 172.10.15.5, + cost: 10, mpls: True, iso: True } + +# - {left: ansible-veos2, left_port: Ethernet2, left_ip: 172.10.23.2, +# right: ansible-veos3, right_port: Ethernet2, right_ip: 172.10.23.3, +# cost: 10, mpls: True, iso: True } + + - {left: ansible-veos2, left_port: Ethernet3, left_ip: 172.10.24.2, + right: ansible-veos4, right_port: Ethernet2, right_ip: 172.10.24.4, + cost: 10, mpls: True, iso: True } + + - {left: ansible-veos2, left_port: Ethernet4, left_ip: 172.10.25.2, + right: ansible-veos5, right_port: Ethernet2, right_ip: 172.10.25.5, + cost: 10, mpls: True, iso: True } + + - {left: ansible-veos3, left_port: Ethernet3, left_ip: 172.10.34.3, + right: ansible-veos4, right_port: Ethernet3, right_ip: 172.10.34.4, + cost: 10, mpls: True, iso: True } + + - {left: ansible-veos3, left_port: Ethernet4, left_ip: 172.10.36.3, + right: ansible-veos6, right_port: Ethernet1, right_ip: 172.10.36.6, + cost: 10, mpls: True, iso: True } + + - {left: ansible-veos4, left_port: Ethernet4, left_ip: 172.10.46.4, + right: ansible-veos6, right_port: Ethernet2, right_ip: 172.10.46.6, + cost: 10, mpls: True, iso: True } + + - {left: ansible-veos5, left_port: Ethernet3, left_ip: 172.10.55.5, + right: ansible-veos55, right_port: Ethernet1, right_ip: 172.10.55.55, + } + + - {left: ansible-veos6, left_port: Ethernet3, left_ip: 172.10.66.6, + right: ansible-veos66, right_port: Ethernet1, right_ip: 172.10.66.66, + } + +bgp: + rr: [10.39.8.41] + clients: [10.39.8.42, 10.39.8.43, 10.39.8.44] + af: + - inet + - inet-vpn + +#ospf: +# area: 0 +# network: p2p + +#isis: +# network: p2p diff --git a/core/core-model.yml b/core/core-model.yml index 61575ad..c7abdfd 100644 --- a/core/core-model.yml +++ b/core/core-model.yml @@ -35,6 +35,10 @@ nodes: iso: 49.0001.0010.0100.1005.00 lu: 163.253.39.165 + - name: ansible-veos55 + mgmt: 10.39.0.155 + rid: 10.39.8.155 + - name: ansible-veos6 mgmt: 10.39.0.56 rid: 10.39.8.56 @@ -42,6 +46,10 @@ nodes: iso: 49.0001.0010.0100.1006.00 lu: 163.253.39.165 + - name: ansible-veos66 + mgmt: 10.39.0.156 + rid: 10.39.8.156 + links: - {left: ansible-vmx1, left_port: ge-0/0/0, left_ip: 172.10.12.1, right: ansible-vmx2, right_port: ge-0/0/0, right_ip: 172.10.12.2, @@ -51,17 +59,17 @@ links: right: ansible-vmx3, right_port: ge-0/0/0, right_ip: 172.10.13.3, cost: 10, mpls: True, iso: True } - - {left: ansible-vmx1, left_port: ge-0/0/2, left_ip: 172.10.14.1, - right: ansible-vmx4, right_port: ge-0/0/0, right_ip: 172.10.14.4, - cost: 10, mpls: True, iso: True } +# - {left: ansible-vmx1, left_port: ge-0/0/2, left_ip: 172.10.14.1, +# right: ansible-vmx4, right_port: ge-0/0/0, right_ip: 172.10.14.4, +# cost: 10, mpls: True, iso: True } - {left: ansible-vmx1, left_port: ge-0/0/3, left_ip: 172.10.15.1, right: ansible-veos5, right_port: Ethernet1, right_ip: 172.10.15.5, cost: 10, mpls: True, iso: True } - - {left: ansible-vmx2, left_port: ge-0/0/1, left_ip: 172.10.23.2, - right: ansible-vmx3, right_port: ge-0/0/1, right_ip: 172.10.23.3, - cost: 10, mpls: True, iso: True } +# - {left: ansible-vmx2, left_port: ge-0/0/1, left_ip: 172.10.23.2, +# right: ansible-vmx3, right_port: ge-0/0/1, right_ip: 172.10.23.3, +# cost: 10, mpls: True, iso: True } - {left: ansible-vmx2, left_port: ge-0/0/2, left_ip: 172.10.24.2, right: ansible-vmx4, right_port: ge-0/0/1, right_ip: 172.10.24.4, @@ -83,17 +91,24 @@ links: right: ansible-veos6, right_port: Ethernet2, right_ip: 172.10.46.6, cost: 10, mpls: True, iso: True } + - {left: ansible-veos5, left_port: Ethernet3, left_ip: 172.10.55.5, + right: ansible-veos55, right_port: Ethernet1, right_ip: 172.10.55.55, + } + + - {left: ansible-veos6, left_port: Ethernet3, left_ip: 172.10.66.6, + right: ansible-veos66, right_port: Ethernet1, right_ip: 172.10.66.66, + } + bgp: rr: [10.39.8.41] clients: [10.39.8.42, 10.39.8.43, 10.39.8.44] af: - inet - inet-vpn - - inet-lu #ospf: # area: 0 # network: p2p -isis: - network: p2p +#isis: +# network: p2p diff --git a/core/core-to-nodes.j2 b/core/core-to-nodes.j2 index 529c361..2111327 100644 --- a/core/core-to-nodes.j2 +++ b/core/core-to-nodes.j2 @@ -15,8 +15,12 @@ nodes: {{ node.name }}: mgmt: {{ node.mgmt }} rid: {{ node.rid }} +{% if node.sid is defined %} sid: {{ node.sid }} +{% endif %} +{% if node.iso is defined %} iso: {{ node.iso }} +{% endif %} links: {% for link in links %} {% if link.left == node.name %} @@ -39,14 +43,17 @@ nodes: {% for peer in bgp.rr %} - {{ peer }} {% endfor %} -{% endif %} -{% if node.lu is defined %} +{% if node.lu is defined %} - {{ node.lu }} -{% endif %} +{% endif %} +{% endif %} af: {% for af in bgp.af %} - {{ af }} {% endfor %} +{% if node.lu is defined %} + - inet-lu +{% endif %} {% endif %} {% if ospf is defined %} ospf: diff --git a/core_config/ansible-veos1-config.txt b/core_config/ansible-veos1-config.txt new file mode 100644 index 0000000..65474fb --- /dev/null +++ b/core_config/ansible-veos1-config.txt @@ -0,0 +1,91 @@ +! +no schedule tech-support +! +transceiver qsfp default-mode 4x10G +! +hostname ansible-veos1 +! +spanning-tree mode mstp +! +no aaa root +! +username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/$WnVBzmLe2LsWQ2kF01jtWff4L9xlxIfCpB0/rS7nWB70dFEoIbIYPRf1LHGg/jSGcR6VdecKvweJxry2vttCR1 +username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 +username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu +! +interface Ethernet4 + no switchport + ip address 172.10.15.1/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet1 + no switchport + ip address 172.10.12.1/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet2 + no switchport + ip address 172.10.13.1/24 + isis enable sr_instance + isis network point-to-point +! +! +! +interface Loopback0 + ip address 10.39.8.41/32 + isis enable sr_instance + node-segment ipv4 index 10 +! +interface Management1 + ip address 10.39.0.41/22 +! +ip route 0.0.0.0/0 10.39.0.1 +! +ip routing +! +ipv6 unicast-routing +! +! +mpls ip +! +mpls label range isis-sr 800000 4096 +! +router bgp 65000 + router-id 10.39.8.41 + ! + neighbor 10.39.8.42 remote-as 65000 + neighbor 10.39.8.42 update-source Management1 + ! + ! + neighbor 10.39.8.43 remote-as 65000 + neighbor 10.39.8.43 update-source Management1 + ! + ! + neighbor 10.39.8.44 remote-as 65000 + neighbor 10.39.8.44 update-source Management1 + ! + ! + ! +! +! +! +router isis sr_instance + net 49.0001.0010.0100.1001.00 + is-type level-2 + log-adjacency-changes + ! + address-family ipv4 unicast + ! + segment-routing mpls + router-id 10.39.8.41 + no shutdown + ! +! +management api http-commands + protocol http + no shutdown +! diff --git a/core_config/ansible-veos2-config.txt b/core_config/ansible-veos2-config.txt new file mode 100644 index 0000000..2514617 --- /dev/null +++ b/core_config/ansible-veos2-config.txt @@ -0,0 +1,83 @@ +! +no schedule tech-support +! +transceiver qsfp default-mode 4x10G +! +hostname ansible-veos2 +! +spanning-tree mode mstp +! +no aaa root +! +username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/$WnVBzmLe2LsWQ2kF01jtWff4L9xlxIfCpB0/rS7nWB70dFEoIbIYPRf1LHGg/jSGcR6VdecKvweJxry2vttCR1 +username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 +username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu +! +interface Ethernet3 + no switchport + ip address 172.10.24.2/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet4 + no switchport + ip address 172.10.25.2/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet1 + no switchport + ip address 172.10.12.2/24 + isis enable sr_instance + isis network point-to-point +! +! +! +interface Loopback0 + ip address 10.39.8.42/32 + isis enable sr_instance + node-segment ipv4 index 20 +! +interface Management1 + ip address 10.39.0.42/22 +! +ip route 0.0.0.0/0 10.39.0.1 +! +ip routing +! +ipv6 unicast-routing +! +! +mpls ip +! +mpls label range isis-sr 800000 4096 +! +router bgp 65000 + router-id 10.39.8.42 + ! + neighbor 10.39.8.41 remote-as 65000 + neighbor 10.39.8.41 update-source Management1 + ! + ! + ! +! +! +! +router isis sr_instance + net 49.0001.0010.0100.1002.00 + is-type level-2 + log-adjacency-changes + ! + address-family ipv4 unicast + ! + segment-routing mpls + router-id 10.39.8.42 + no shutdown + ! +! +management api http-commands + protocol http + no shutdown +! diff --git a/core_config/ansible-veos3-config.txt b/core_config/ansible-veos3-config.txt new file mode 100644 index 0000000..53a4373 --- /dev/null +++ b/core_config/ansible-veos3-config.txt @@ -0,0 +1,83 @@ +! +no schedule tech-support +! +transceiver qsfp default-mode 4x10G +! +hostname ansible-veos3 +! +spanning-tree mode mstp +! +no aaa root +! +username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/$WnVBzmLe2LsWQ2kF01jtWff4L9xlxIfCpB0/rS7nWB70dFEoIbIYPRf1LHGg/jSGcR6VdecKvweJxry2vttCR1 +username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 +username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu +! +interface Ethernet3 + no switchport + ip address 172.10.34.3/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet4 + no switchport + ip address 172.10.36.3/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet1 + no switchport + ip address 172.10.13.3/24 + isis enable sr_instance + isis network point-to-point +! +! +! +interface Loopback0 + ip address 10.39.8.43/32 + isis enable sr_instance + node-segment ipv4 index 30 +! +interface Management1 + ip address 10.39.0.43/22 +! +ip route 0.0.0.0/0 10.39.0.1 +! +ip routing +! +ipv6 unicast-routing +! +! +mpls ip +! +mpls label range isis-sr 800000 4096 +! +router bgp 65000 + router-id 10.39.8.43 + ! + neighbor 10.39.8.41 remote-as 65000 + neighbor 10.39.8.41 update-source Management1 + ! + ! + ! +! +! +! +router isis sr_instance + net 49.0001.0010.0100.1003.00 + is-type level-2 + log-adjacency-changes + ! + address-family ipv4 unicast + ! + segment-routing mpls + router-id 10.39.8.43 + no shutdown + ! +! +management api http-commands + protocol http + no shutdown +! diff --git a/core_config/ansible-veos4-config.txt b/core_config/ansible-veos4-config.txt new file mode 100644 index 0000000..41744a3 --- /dev/null +++ b/core_config/ansible-veos4-config.txt @@ -0,0 +1,83 @@ +! +no schedule tech-support +! +transceiver qsfp default-mode 4x10G +! +hostname ansible-veos4 +! +spanning-tree mode mstp +! +no aaa root +! +username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/$WnVBzmLe2LsWQ2kF01jtWff4L9xlxIfCpB0/rS7nWB70dFEoIbIYPRf1LHGg/jSGcR6VdecKvweJxry2vttCR1 +username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 +username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu +! +interface Ethernet3 + no switchport + ip address 172.10.34.4/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet4 + no switchport + ip address 172.10.46.4/24 + isis enable sr_instance + isis network point-to-point +! +! +interface Ethernet2 + no switchport + ip address 172.10.24.4/24 + isis enable sr_instance + isis network point-to-point +! +! +! +interface Loopback0 + ip address 10.39.8.44/32 + isis enable sr_instance + node-segment ipv4 index 40 +! +interface Management1 + ip address 10.39.0.44/22 +! +ip route 0.0.0.0/0 10.39.0.1 +! +ip routing +! +ipv6 unicast-routing +! +! +mpls ip +! +mpls label range isis-sr 800000 4096 +! +router bgp 65000 + router-id 10.39.8.44 + ! + neighbor 10.39.8.41 remote-as 65000 + neighbor 10.39.8.41 update-source Management1 + ! + ! + ! +! +! +! +router isis sr_instance + net 49.0001.0010.0100.1004.00 + is-type level-2 + log-adjacency-changes + ! + address-family ipv4 unicast + ! + segment-routing mpls + router-id 10.39.8.44 + no shutdown + ! +! +management api http-commands + protocol http + no shutdown +! diff --git a/core_config/ansible-veos5-config.txt b/core_config/ansible-veos5-config.txt index 471d4a5..e78cf3a 100644 --- a/core_config/ansible-veos5-config.txt +++ b/core_config/ansible-veos5-config.txt @@ -13,6 +13,11 @@ username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/ username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu ! +interface Ethernet3 + no switchport + ip address 172.10.55.5/24 +! +! interface Ethernet1 no switchport ip address 172.10.15.5/24 diff --git a/core_config/ansible-veos55-config.txt b/core_config/ansible-veos55-config.txt new file mode 100644 index 0000000..24d84f4 --- /dev/null +++ b/core_config/ansible-veos55-config.txt @@ -0,0 +1,54 @@ +! +no schedule tech-support +! +transceiver qsfp default-mode 4x10G +! +hostname ansible-veos55 +! +spanning-tree mode mstp +! +no aaa root +! +username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/$WnVBzmLe2LsWQ2kF01jtWff4L9xlxIfCpB0/rS7nWB70dFEoIbIYPRf1LHGg/jSGcR6VdecKvweJxry2vttCR1 +username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 +username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu +! +interface Ethernet1 + no switchport + ip address 172.10.55.55/24 +! +! +! +interface Loopback0 + ip address 10.39.8.155/32 +! +interface Management1 + ip address 10.39.0.155/22 +! +ip route 0.0.0.0/0 10.39.0.1 +! +ip routing +! +ipv6 unicast-routing +! +! +mpls ip +! +mpls label range isis-sr 800000 4096 +! +router bgp 65000 + router-id 10.39.8.155 + ! + neighbor 10.39.8.41 remote-as 65000 + neighbor 10.39.8.41 update-source Management1 + ! + ! + ! +! +! +! +! +management api http-commands + protocol http + no shutdown +! diff --git a/core_config/ansible-veos6-config.txt b/core_config/ansible-veos6-config.txt index 67745ab..c160405 100644 --- a/core_config/ansible-veos6-config.txt +++ b/core_config/ansible-veos6-config.txt @@ -13,6 +13,11 @@ username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/ username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu ! +interface Ethernet3 + no switchport + ip address 172.10.66.6/24 +! +! interface Ethernet1 no switchport ip address 172.10.36.6/24 diff --git a/core_config/ansible-veos66-config.txt b/core_config/ansible-veos66-config.txt new file mode 100644 index 0000000..56a6a91 --- /dev/null +++ b/core_config/ansible-veos66-config.txt @@ -0,0 +1,54 @@ +! +no schedule tech-support +! +transceiver qsfp default-mode 4x10G +! +hostname ansible-veos66 +! +spanning-tree mode mstp +! +no aaa root +! +username admin privilege 15 role network-admin secret sha512 $6$QooVHYszFBY655A/$WnVBzmLe2LsWQ2kF01jtWff4L9xlxIfCpB0/rS7nWB70dFEoIbIYPRf1LHGg/jSGcR6VdecKvweJxry2vttCR1 +username salt privilege 15 role network-admin secret sha512 $6$gNfDGxuNqAufb7SS$XuBAZwDyHEX6Bt6zgDBA0zkJLhOm.5aJ8cwy2wd21DVr9yWr.gqwYBx7NUntbvSjTlKDQBg.XsMIIYRwqU10u1 +username salt sshkey ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCjxY2hLZ+ju5wdK4GYNhKGgnS8EWLBoEVpo+xQkhDzkTiBx3HGAnmARcVV0B9MqrHZl1omdnirJeygWzVbVY4yPUqGgEcUsTTq9fvK4AjTwtaoB5txAosaOnZq0zewmuZ6EMi6E3RND6A3FGXkf1Il2jg3I8k/dGqdyFI80B7sWy90fk+EqsGMPxVc+l5vAtY2jm84ellxxzBsulxfCSKPH86hZ1GqZ8A1ZBWITu15NjQw0aGssSYGMMTa1T8eFyY4hHWqqdwgOlODg9mZwwP1JdJH79SRoTOjqGGixuAFDGAgH3fNX6u8wTmYya/z7WXH6B2XwiiaZYdcyEbMLPZt knewell@ubuntu +! +interface Ethernet1 + no switchport + ip address 172.10.66.66/24 +! +! +! +interface Loopback0 + ip address 10.39.8.156/32 +! +interface Management1 + ip address 10.39.0.156/22 +! +ip route 0.0.0.0/0 10.39.0.1 +! +ip routing +! +ipv6 unicast-routing +! +! +mpls ip +! +mpls label range isis-sr 800000 4096 +! +router bgp 65000 + router-id 10.39.8.156 + ! + neighbor 10.39.8.41 remote-as 65000 + neighbor 10.39.8.41 update-source Management1 + ! + ! + ! +! +! +! +! +management api http-commands + protocol http + no shutdown +! diff --git a/core_config/ansible-vmx1-config.txt b/core_config/ansible-vmx1-config.txt index 1cd49c9..e37c024 100644 --- a/core_config/ansible-vmx1-config.txt +++ b/core_config/ansible-vmx1-config.txt @@ -63,17 +63,6 @@ interfaces { } } - ge-0/0/2 { - description "ansible-vmx4" - unit 0 { - family inet { - address 172.10.14.1/24 - } - family mpls; - family iso; - } - } - ge-0/0/3 { description "ansible-veos5" unit 0 { @@ -147,9 +136,6 @@ protocols { interface ge-0/0/1.0 { point-to-point; } - interface ge-0/0/2.0 { - point-to-point; - } interface ge-0/0/3.0 { point-to-point; } @@ -160,26 +146,22 @@ protocols { ldp { interface ge-0/0/0.0; interface ge-0/0/1.0; - interface ge-0/0/2.0; interface ge-0/0/3.0; interface lo0.0; } rsvp { interface ge-0/0/0.0; interface ge-0/0/1.0; - interface ge-0/0/2.0; interface ge-0/0/3.0; } mpls { interface ge-0/0/0.0; interface ge-0/0/1.0; - interface ge-0/0/2.0; interface ge-0/0/3.0; } lldp { interface ge-0/0/0; interface ge-0/0/1; - interface ge-0/0/2; interface ge-0/0/3; } } diff --git a/core_config/ansible-vmx2-config.txt b/core_config/ansible-vmx2-config.txt index 019fe57..295c263 100644 --- a/core_config/ansible-vmx2-config.txt +++ b/core_config/ansible-vmx2-config.txt @@ -52,17 +52,6 @@ interfaces { } } - ge-0/0/1 { - description "ansible-vmx3" - unit 0 { - family inet { - address 172.10.23.2/24 - } - family mpls; - family iso; - } - } - ge-0/0/2 { description "ansible-vmx4" unit 0 { @@ -142,9 +131,6 @@ protocols { interface ge-0/0/0.0 { point-to-point; } - interface ge-0/0/1.0 { - point-to-point; - } interface ge-0/0/2.0 { point-to-point; } @@ -157,26 +143,22 @@ protocols { } ldp { interface ge-0/0/0.0; - interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; interface lo0.0; } rsvp { interface ge-0/0/0.0; - interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; } mpls { interface ge-0/0/0.0; - interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; } lldp { interface ge-0/0/0; - interface ge-0/0/1; interface ge-0/0/2; interface ge-0/0/3; } diff --git a/core_config/ansible-vmx3-config.txt b/core_config/ansible-vmx3-config.txt index a4c691a..e8a5f29 100644 --- a/core_config/ansible-vmx3-config.txt +++ b/core_config/ansible-vmx3-config.txt @@ -52,17 +52,6 @@ interfaces { } } - ge-0/0/1 { - description "ansible-vmx2" - unit 0 { - family inet { - address 172.10.23.3/24 - } - family mpls; - family iso; - } - } - ge-0/0/2 { description "ansible-vmx4" unit 0 { @@ -142,9 +131,6 @@ protocols { interface ge-0/0/0.0 { point-to-point; } - interface ge-0/0/1.0 { - point-to-point; - } interface ge-0/0/2.0 { point-to-point; } @@ -157,26 +143,22 @@ protocols { } ldp { interface ge-0/0/0.0; - interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; interface lo0.0; } rsvp { interface ge-0/0/0.0; - interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; } mpls { interface ge-0/0/0.0; - interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; } lldp { interface ge-0/0/0; - interface ge-0/0/1; interface ge-0/0/2; interface ge-0/0/3; } diff --git a/core_config/ansible-vmx4-config.txt b/core_config/ansible-vmx4-config.txt index 9e8ea07..27ba03d 100644 --- a/core_config/ansible-vmx4-config.txt +++ b/core_config/ansible-vmx4-config.txt @@ -41,17 +41,6 @@ system { } interfaces { - ge-0/0/0 { - description "ansible-vmx1" - unit 0 { - family inet { - address 172.10.14.4/24 - } - family mpls; - family iso; - } - } - ge-0/0/1 { description "ansible-vmx2" unit 0 { @@ -139,9 +128,6 @@ protocols { } } level 1 disable; - interface ge-0/0/0.0 { - point-to-point; - } interface ge-0/0/1.0 { point-to-point; } @@ -156,26 +142,22 @@ protocols { } } ldp { - interface ge-0/0/0.0; interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; interface lo0.0; } rsvp { - interface ge-0/0/0.0; interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; } mpls { - interface ge-0/0/0.0; interface ge-0/0/1.0; interface ge-0/0/2.0; interface ge-0/0/3.0; } lldp { - interface ge-0/0/0; interface ge-0/0/1; interface ge-0/0/2; interface ge-0/0/3; diff --git a/eos/core.j2 b/eos/core.j2 index 3a79921..0eaacc7 100644 --- a/eos/core.j2 +++ b/eos/core.j2 @@ -20,8 +20,10 @@ interface {{intf.split('.')[0]}} {% if intf_attr.vlan is undefined or intf_attr.vlan == 0 %} ip address {{intf_attr.ip}}/{{intf_attr.mask|default('24')}} {% endif %} +{% if intf_attr.iso is defined %} isis enable sr_instance isis network point-to-point +{% endif %} ! {% if intf_attr.vlan is defined and intf_attr.vlan != 0 %} interface {{intf}} @@ -33,8 +35,12 @@ interface {{intf}} ! interface Loopback0 ip address {{node.rid}}/32 +{% if node.iso is defined %} isis enable sr_instance +{% endif %} +{% if node.sid is defined %} node-segment ipv4 index {{node.sid}} +{% endif %} ! interface Management1 ip address {{node.mgmt}}/22 @@ -96,7 +102,7 @@ mpls ldp {% endfor %} #} ! -{% if node.isis is defined %} +{% if node.iso is defined %} router isis sr_instance net {{node.iso}} is-type level-2 diff --git a/hosts b/hosts index d385d4f..2f2c9d9 100644 --- a/hosts +++ b/hosts @@ -21,3 +21,7 @@ all: ansible_host: 10.39.0.55 ansible-veos6: ansible_host: 10.39.0.56 + ansible-veos55: + ansible_host: 10.39.0.155 + ansible-veos66: + ansible_host: 10.39.0.156 diff --git a/hosts_veos b/hosts_veos new file mode 100644 index 0000000..94faa61 --- /dev/null +++ b/hosts_veos @@ -0,0 +1,25 @@ +--- +all: + children: + eos: + children: + veos: + hosts: + ansible-veos1: + ansible_host: 10.39.0.41 + ansible-veos2: + ansible_host: 10.39.0.42 + ansible-veos3: + ansible_host: 10.39.0.43 + ansible-veos4: + ansible_host: 10.39.0.44 + ansible-veos5: + ansible_host: 10.39.0.55 + ansible-veos6: + ansible_host: 10.39.0.56 + ansible-veos55: + ansible_host: 10.39.0.155 + ansible-veos66: + ansible_host: 10.39.0.156 + vars: + model: core-model-veos.yml diff --git a/junos/core.j2 b/junos/core.j2 index e4aec30..ef28eb7 100644 --- a/junos/core.j2 +++ b/junos/core.j2 @@ -189,7 +189,7 @@ protocols { ### ISIS Variables ###### ************************************************** #} -{% if node.isis is defined %} +{% if node.iso is defined %} isis { no-ipv6-routing; source-packet-routing { diff --git a/nodes.yml b/nodes.yml index b0bfebb..ae0fb44 100644 --- a/nodes.yml +++ b/nodes.yml @@ -9,16 +9,15 @@ common: nodes: - ansible-vmx1: + ansible-veos1: mgmt: 10.39.0.41 rid: 10.39.8.41 sid: 10 iso: 49.0001.0010.0100.1001.00 links: - ge-0/0/0.0: { ip: 172.10.12.1, remote: ansible-vmx2 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/1.0: { ip: 172.10.13.1, remote: ansible-vmx3 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/2.0: { ip: 172.10.14.1, remote: ansible-vmx4 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/3.0: { ip: 172.10.15.1, remote: ansible-veos5 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet1.0: { ip: 172.10.12.1, remote: ansible-veos2 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet2.0: { ip: 172.10.13.1, remote: ansible-veos3 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet4.0: { ip: 172.10.15.1, remote: ansible-veos5 , cost: 10 , vlan: 0 , mpls: True , iso: True} bgp: ibgp: rr: true @@ -29,20 +28,16 @@ nodes: af: - inet - inet-vpn - - inet-lu - isis: - network: p2p - ansible-vmx2: + ansible-veos2: mgmt: 10.39.0.42 rid: 10.39.8.42 sid: 20 iso: 49.0001.0010.0100.1002.00 links: - ge-0/0/0.0: { ip: 172.10.12.2, remote: ansible-vmx1 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/1.0: { ip: 172.10.23.2, remote: ansible-vmx3 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/2.0: { ip: 172.10.24.2, remote: ansible-vmx4 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/3.0: { ip: 172.10.25.2, remote: ansible-veos5 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet1.0: { ip: 172.10.12.2, remote: ansible-veos1 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet3.0: { ip: 172.10.24.2, remote: ansible-veos4 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet4.0: { ip: 172.10.25.2, remote: ansible-veos5 , cost: 10 , vlan: 0 , mpls: True , iso: True} bgp: ibgp: peers: @@ -50,20 +45,16 @@ nodes: af: - inet - inet-vpn - - inet-lu - isis: - network: p2p - ansible-vmx3: + ansible-veos3: mgmt: 10.39.0.43 rid: 10.39.8.43 sid: 30 iso: 49.0001.0010.0100.1003.00 links: - ge-0/0/0.0: { ip: 172.10.13.3, remote: ansible-vmx1 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/1.0: { ip: 172.10.23.3, remote: ansible-vmx2 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/2.0: { ip: 172.10.34.3, remote: ansible-vmx4 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/3.0: { ip: 172.10.36.3, remote: ansible-veos6 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet1.0: { ip: 172.10.13.3, remote: ansible-veos1 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet3.0: { ip: 172.10.34.3, remote: ansible-veos4 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet4.0: { ip: 172.10.36.3, remote: ansible-veos6 , cost: 10 , vlan: 0 , mpls: True , iso: True} bgp: ibgp: peers: @@ -71,20 +62,16 @@ nodes: af: - inet - inet-vpn - - inet-lu - isis: - network: p2p - ansible-vmx4: + ansible-veos4: mgmt: 10.39.0.44 rid: 10.39.8.44 sid: 40 iso: 49.0001.0010.0100.1004.00 links: - ge-0/0/0.0: { ip: 172.10.14.4, remote: ansible-vmx1 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/1.0: { ip: 172.10.24.4, remote: ansible-vmx2 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/2.0: { ip: 172.10.34.4, remote: ansible-vmx3 , cost: 10 , vlan: 0 , mpls: True , iso: True} - ge-0/0/3.0: { ip: 172.10.46.4, remote: ansible-veos6 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet2.0: { ip: 172.10.24.4, remote: ansible-veos2 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet3.0: { ip: 172.10.34.4, remote: ansible-veos3 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet4.0: { ip: 172.10.46.4, remote: ansible-veos6 , cost: 10 , vlan: 0 , mpls: True , iso: True} bgp: ibgp: peers: @@ -92,9 +79,6 @@ nodes: af: - inet - inet-vpn - - inet-lu - isis: - network: p2p ansible-veos5: mgmt: 10.39.0.55 @@ -102,8 +86,9 @@ nodes: sid: 50 iso: 49.0001.0010.0100.1005.00 links: - Ethernet1.0: { ip: 172.10.15.5, remote: ansible-vmx1 , cost: 10 , vlan: 0 , mpls: True , iso: True} - Ethernet2.0: { ip: 172.10.25.5, remote: ansible-vmx2 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet1.0: { ip: 172.10.15.5, remote: ansible-veos1 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet2.0: { ip: 172.10.25.5, remote: ansible-veos2 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet3.0: { ip: 172.10.55.5, remote: ansible-veos55 , vlan: 0 } bgp: ibgp: peers: @@ -113,8 +98,19 @@ nodes: - inet - inet-vpn - inet-lu - isis: - network: p2p + + ansible-veos55: + mgmt: 10.39.0.155 + rid: 10.39.8.155 + links: + Ethernet1.0: { ip: 172.10.55.55, remote: ansible-veos5 , vlan: 0 } + bgp: + ibgp: + peers: + - 10.39.8.41 + af: + - inet + - inet-vpn ansible-veos6: mgmt: 10.39.0.56 @@ -122,8 +118,9 @@ nodes: sid: 60 iso: 49.0001.0010.0100.1006.00 links: - Ethernet1.0: { ip: 172.10.36.6, remote: ansible-vmx3 , cost: 10 , vlan: 0 , mpls: True , iso: True} - Ethernet2.0: { ip: 172.10.46.6, remote: ansible-vmx4 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet1.0: { ip: 172.10.36.6, remote: ansible-veos3 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet2.0: { ip: 172.10.46.6, remote: ansible-veos4 , cost: 10 , vlan: 0 , mpls: True , iso: True} + Ethernet3.0: { ip: 172.10.66.6, remote: ansible-veos66 , vlan: 0 } bgp: ibgp: peers: @@ -133,5 +130,16 @@ nodes: - inet - inet-vpn - inet-lu - isis: - network: p2p + + ansible-veos66: + mgmt: 10.39.0.156 + rid: 10.39.8.156 + links: + Ethernet1.0: { ip: 172.10.66.66, remote: ansible-veos6 , vlan: 0 } + bgp: + ibgp: + peers: + - 10.39.8.41 + af: + - inet + - inet-vpn