-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest_module_health_checks.yml
95 lines (84 loc) · 3.77 KB
/
test_module_health_checks.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
# Copyright 2024 Cisco Systems, Inc. and its affiliates
# GNU General Public License v3.0+ (see LICENSE or https://www.gnu.org/licenses/gpl-3.0.txt)
---
# Helper playbooks to test modules and flows while developing them
# Tested operations: All possible health checks
- name: Testing playbook to verify cisco.catalystwan.health_checks module operations
hosts: localhost
gather_facts: false
vars_files:
- configuration_file_dev_vars.yml
tasks:
- name: "Health check: control connections - verifies if all have state up"
cisco.catalystwan.health_checks:
check_type: control_connections
manager_authentication:
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"
- name: "Health check: orchestrator connections - verifies if all have state up"
cisco.catalystwan.health_checks:
check_type: orchestrator_connections
manager_authentication:
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"
- name: |
"Health check: system status with health metrics - vmanage:
- cpu_state == normal
- mem_state == normal
- mem_usaage <= 90
- device_status == normal
- device_reachablitiy = reachable
cisco.catalystwan.health_checks:
check_type: device_system_status
filters:
personality: "vmanage"
manager_authentication:
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"
- name: |
"Health check: system status with health metrics - vsmart:
- cpu_state == normal
- mem_state == normal
- mem_usaage <= 90
- device_status == normal
- device_reachablitiy = reachable
cisco.catalystwan.health_checks:
check_type: device_system_status
filters:
personality: "vsmart"
manager_authentication:
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"
- name: |
"Health check: system status with health metrics - vbond:
- cpu_state == normal
- mem_state == normal
- mem_usaage <= 90
- device_status == normal
- device_reachablitiy = reachable
cisco.catalystwan.health_checks:
check_type: device_system_status
filters:
personality: "vbond"
manager_authentication:
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"
- name: "Health check: BFD sessions - verifies if all have state up"
cisco.catalystwan.health_checks:
check_type: bfd
manager_authentication:
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"
- name: "Health check: OMP sessions - verifies if all have state up"
cisco.catalystwan.health_checks:
check_type: omp
manager_authentication:
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"