-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path02-deploy-exos-switch.yaml
88 lines (71 loc) · 2.79 KB
/
02-deploy-exos-switch.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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
- name: ExtremeOS Gyostage2019 ASENNUSPOYTA
hosts: EX-20
vars:
ACCESS_VLAN: 10
ACCESS_PORTS: 1-24
UPLINK_PORTS: 25-26
tasks:
- name: DELETING DEFAULT VLAN FROM ALL PORTS ...
exos_config:
lines:
- configure vlan default delete ports all
- name: CREATING VLANS ...
exos_config:
lines:
- create vlan VLAN{{ ACCESS_VLAN }}
- configure vlan VLAN{{ ACCESS_VLAN }} tag {{ ACCESS_VLAN }}
- name: CONFIGURING VLANS TO TRUNK PORTS ...
exos_config:
lines:
- configure vlan VLAN{{ ACCESS_VLAN }} add ports {{ UPLINK_PORTS }} tagged
- configure vlan "VLAN99" add ports {{ UPLINK_PORTS }} tagged
- configure ports {{ UPLINK_PORTS }} description-string UPLINK
- name: CONFIGURING VLANS TO ACCESS PORTS ...
exos_config:
lines:
- configure vlan VLAN{{ ACCESS_VLAN }} add ports {{ ACCESS_PORTS }} untagged
- configure ports 1-24 description-string KONEPAIKKA
- name: CONFIGURING LOOP-PROTECTION TO ACCESS PORTS ...
exos_config:
lines:
- enable elrp-client
- configure elrp-client periodic VLAN{{ ACCESS_VLAN }} ports {{ ACCESS_PORTS }} interval 1 log disable-port duration 15
- name: CONFIGURING LOOP-PROTECTION EXCLUDES TO UPLINKS ...
exos_config:
lines:
- configure elrp-client disable-port exclude {{ UPLINK_PORTS }}
- name: CONFIGURING DHCP-SNOOPING TRUST TO UPLINKS ...
exos_config:
lines:
- configure trusted-ports {{ UPLINK_PORTS }} trust-for dhcp-server
- name: CONFIGURING DHCP-SNOOPING TO ACCESS PORTS ...
exos_config:
lines:
- enable ip-security dhcp-snooping vlan VLAN{{ ACCESS_VLAN }} ports {{ ACCESS_PORTS }} violation-action drop-packet snmp-trap
- name: CONFIGURING IGMP-SNOOPING TO ACCESS VLAN ...
exos_config:
lines:
- enable igmp snooping vlan VLAN{{ ACCESS_VLAN }}
- name: CONFIGURING MAC-LIMIT TO ACCESS PORTS ...
exos_config:
lines:
- configure ports {{ ACCESS_PORTS }} vlan VLAN{{ ACCESS_VLAN }} limit-learning 1 action stop-learning
- name: CONFIGURING STORM CONTROL TO ACCESS PORTS ...
exos_config:
lines:
- configure ports {{ ACCESS_PORTS }} rate-limit flood broadcast 1000
- configure ports {{ ACCESS_PORTS }} rate-limit flood unknown-destmac 1000
- name: CONFIGURING SNMP SETTINGS ...
exos_config:
lines:
- configure snmp sysName "{{ inventory_hostname }}"
- configure snmp sysLocation "GYOSTAGE2019"
- configure snmp sysContact "[email protected]"
- name: Configure SNTP-settings
exos_config:
lines:
- enable sntp-client
- configure sntp-client primary 10.44.99.1 vr VR-Default
- name: Save running config to startup when modified
exos_config:
save_when: modified