-
Notifications
You must be signed in to change notification settings - Fork 2
/
erx1-bgp.yaml
50 lines (43 loc) · 2.27 KB
/
erx1-bgp.yaml
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
40
41
42
43
44
45
46
47
48
49
---
- hosts: erx1.gxize.local
vars:
ansible_connection: network_cli
ansible_network_os: edgeos
tasks:
- name: backup config locally
community.network.edgeos_config:
backup: yes
- name: ... SERVICE-PREFIXES prefix-list, STATIC-TO-BGP route-map
community.network.edgeos_config:
lines:
- set policy prefix-list SERVICE-PREFIXES rule 10 action permit
- set policy prefix-list SERVICE-PREFIXES rule 10 prefix 10.22.22.0/24
- set policy prefix-list SERVICE-PREFIXES rule 20 action permit
- set policy prefix-list SERVICE-PREFIXES rule 20 prefix 10.16.87.0/24
- set policy prefix-list SERVICE-PREFIXES rule 30 action permit
- set policy prefix-list SERVICE-PREFIXES rule 30 prefix 10.40.0.0/15
- set policy prefix-list SERVICE-PREFIXES rule 40 action permit
- set policy prefix-list SERVICE-PREFIXES rule 40 prefix 172.29.100.0/24
- set policy route-map STATIC-TO-BGP rule 10 action permit
- set policy route-map STATIC-TO-BGP rule 10 match ip address prefix-list SERVICE-PREFIXES
- name: ... general bgp options
community.network.edgeos_config:
lines:
- set protocols bgp 65020 network 10.0.0.0/8
- set protocols bgp 65020 network 172.16.0.0/12
- set protocols bgp 65020 parameters router-id 10.16.87.101
- set protocols bgp 65020 redistribute static route-map STATIC-TO-BGP
- name: ... bgp neighbor -- hexs760
community.network.edgeos_config:
lines:
- set protocols bgp 65020 neighbor 10.16.96.211 description hexs760
- set protocols bgp 65020 neighbor 10.16.96.211 nexthop-self
- set protocols bgp 65020 neighbor 10.16.96.211 remote-as 65020
- set protocols bgp 65020 neighbor 10.16.96.211 soft-reconfiguration inbound
- name: ... bgp neighbor -- calico-node n1208_rocket
community.network.edgeos_config:
lines:
- set protocols bgp 65020 neighbor 10.22.22.111 description n1208_rocket
- set protocols bgp 65020 neighbor 10.22.22.111 nexthop-self
- set protocols bgp 65020 neighbor 10.22.22.111 remote-as 65020
- set protocols bgp 65020 neighbor 10.22.22.111 soft-reconfiguration inbound