-
Notifications
You must be signed in to change notification settings - Fork 33
/
Copy pathsnmp.yml
144 lines (133 loc) · 3.89 KB
/
snmp.yml
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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
---
# Copyright 2019 Broadcom. All rights reserved.
# The term 'Broadcom' refers to Broadcom Inc. and/or its subsidiaries.
# GNU General Public License v3.0+
# (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
- hosts: san_eng_zone_seed_san_a
gather_facts: False
vars:
credential:
fos_ip_addr: "{{fos_ip_addr}}"
fos_user_name: "{{fos_user_name}}"
fos_password: "{{fos_password}}"
https: "{{fos_https}}"
snmp_system:
audit_interval: 60
contact: "more Field Support."
description: "more DemoSwitch"
encryption_enabled: True
informs_enabled: True
location: "more San Jose"
security_get_level: 0
security_set_level: 3
snmpv1_enabled: False
v1_accounts:
- index: 1
community_name: "Secret code new"
community_group: "read-write"
- index: 2
community_name: "OrigEquipMfr new"
community_group: "read-write"
- index: 3
community_name: "private"
community_group: "read-write"
- index: 4
community_name: "public"
community_group: "read-only"
- index: 5
community_name: "common"
community_group: "read-only"
- index: 6
community_name: "FibreChannelNew"
community_group: "read-only"
v1_traps:
- index: 1
host: "10.10.10.12"
port_number: 1002
trap_severity_level: "warning"
v3_accounts:
- index: 1
authentication_protocol: "md5"
manager_engine_id: "00:00:00:00:00:00:00:00:00"
privacy_protocol: "aes128"
user_name: "asc-test"
- index: 2
authentication_protocol: "sha"
manager_engine_id: "00:00:00:00:00:00:00:00:00"
privacy_protocol: "des"
user_name: "snmpadmin2"
v3_traps:
- trap_index: 1
host: "10.10.10.11"
informs_enabled: true
port_number: 1011
trap_severity_level: "warning"
usm_index: 1
- trap_index: 2
host: "10.10.10.10"
informs_enabled: false
port_number: 1010
trap_severity_level: "critical"
usm_index: 2
- trap_index: 3
host: "0.0.0.0"
informs_enabled: false
port_number: 162
trap_severity_level: "none"
usm_index: 3
- trap_index: 4
host: "0.0.0.0"
informs_enabled: false
port_number: 162
trap_severity_level: "none"
usm_index: 4
- trap_index: 5
host: "0.0.0.0"
informs_enabled: false
port_number: 162
trap_severity_level: "none"
usm_index: 5
- trap_index: 6
host: "0.0.0.0"
informs_enabled: false
port_number: 162
trap_severity_level: "none"
usm_index: 6
v3_accounts_passwords_only:
- index: 1
authentication_password: "password1"
privacy_password: "password1"
- index: 2
authentication_password: "password2"
privacy_password: "password"
tasks:
- name: change all snmp system configuration
brocade_snmp_system:
credential: "{{credential}}"
vfid: -1
snmp_system: "{{snmp_system}}"
- name: v1 accounts
brocade_snmp_v1_account:
credential: "{{credential}}"
vfid: -1
v1_accounts: "{{v1_accounts}}"
- name: v1 traps
brocade_snmp_v1_trap:
credential: "{{credential}}"
vfid: -1
v1_traps: "{{v1_traps}}"
- name: v3 accounts - setup non-password attributes
brocade_snmp_v3_account:
credential: "{{credential}}"
vfid: -1
v3_accounts: "{{v3_accounts}}"
- name: v3 traps
brocade_snmp_v3_trap:
credential: "{{credential}}"
vfid: -1
v3_traps: "{{v3_traps}}"
- name: v3 accounts - set passwords. warning - password cannot be read. this task will always change.
brocade_snmp_v3_account:
credential: "{{credential}}"
vfid: -1
v3_accounts: "{{v3_accounts_passwords_only}}"