Debian Codegraph @

ansible_collections/dellemc/openmanage/playbooks/ome/alert_policy/ome_alert_policies.yml

raw symbols SCIP
1 ---
2 - name: Dell OpenManage Ansible Alert policies.
3 hosts: ome
4 gather_facts: false
5
6 tasks:
7 - name: "Create an alert policy"
8 dellemc.openmanage.ome_alert_policies:
9 hostname: "{{ hostname }}"
10 username: "{{ username }}"
11 password: "{{ password }}"
12 ca_path: "/path/to/ca_cert.pem"
13 name: "Alert Policy One"
14 device_service_tag:
15 - ABCD123
16 - SVC7845
17 category:
18 - catalog_name: Application
19 catalog_category:
20 - category_name: Audit
21 sub_category_names:
22 - Generic
23 - Devices
24 - catalog_name: iDRAC
25 catalog_category:
26 - category_name: Audit
27 sub_category_names:
28 - BIOS Management
29 - iDRAC Service Module
30 date_and_time:
31 date_from: "2023-10-10"
32 date_to: "2023-10-11"
33 time_from: "11:00"
34 time_to: "12:00"
35 time_interval: true
36 severity:
37 - unknown
38 - critical
39 actions:
40 - action_name: Trap
41 parameters:
42 - name: "192.1.2.3:162"
43 value: true
44 - name: "traphostname.domain.com:162"
45 value: true
46 tags: create_alert_policy
47 delegate_to: localhost
48
49 - name: "Update an alert Policy"
50 dellemc.openmanage.ome_alert_policies:
51 hostname: "{{ hostname }}"
52 username: "{{ username }}"
53 password: "{{ password }}"
54 ca_path: "/path/to/ca_cert.pem"
55 name: "Existing Policy Name"
56 new_name: "Update Policy Name"
57 device_group: "Group Name"
58 message_ids:
59 - AMP400
60 - CTL201
61 - BIOS101
62 date_and_time:
63 date_from: "2023-10-10"
64 date_to: "2023-10-11"
65 time_from: "11:00"
66 time_to: "12:00"
67 time_interval: true
68 actions:
69 - action_name: Trap
70 parameters:
71 - name: "192.1.2.3:162"
72 value: true
73 tags: update_alert_policy
74 delegate_to: localhost
75
76 - name: "Enable an alert policy"
77 dellemc.openmanage.ome_alert_policies:
78 hostname: "{{ hostname }}"
79 username: "{{ username }}"
80 password: "{{ password }}"
81 ca_path: "/path/to/ca_cert.pem"
82 name: "Policy Name"
83 enable: true
84 tags: enable_alert_policy
85 delegate_to: localhost
86
87 - name: "Disable multiple alert policies"
88 dellemc.openmanage.ome_alert_policies:
89 hostname: "{{ hostname }}"
90 username: "{{ username }}"
91 password: "{{ password }}"
92 ca_path: "/path/to/ca_cert.pem"
93 name:
94 - "Policy Name 1"
95 - "Policy Name 2"
96 enable: false
97 tags: disable_alert_policy
98 delegate_to: localhost
99
100 - name: "Delete an alert policy"
101 dellemc.openmanage.ome_alert_policies:
102 hostname: "{{ hostname }}"
103 username: "{{ username }}"
104 password: "{{ password }}"
105 ca_path: "/path/to/ca_cert.pem"
106 name:
107 - "Policy Name"
108 state: absent
109 tags: delete_alert_policy
110 delegate_to: localhost