-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest_device_templates.yml
50 lines (43 loc) · 1.8 KB
/
test_device_templates.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
# 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
# --- Device Templates --- #
- name: Testing playbook to verify cisco.catalystwan.device_templates module operations
hosts: localhost
gather_facts: false
vars_files:
- configuration_file_dev_vars.yml
vars:
manager_authentication: &manager_authentication
url: "{{ (vmanage_instances | first).mgmt_public_ip }}"
username: "{{ (vmanage_instances | first).admin_username }}"
password: "{{ (vmanage_instances | first).admin_password }}"
tasks:
- name: 1. Get all Non-Default Device Templates available
cisco.catalystwan.device_templates_info:
filters:
factory_default: false
manager_credentials:
<<: *manager_authentication
register: device_templates
- name: 2. Delete selected Device Template from vManage
cisco.catalystwan.device_templates:
state: absent
template_name: "vc8000-device-template"
manager_credentials:
<<: *manager_authentication
- name: 3. Create example Device Template with default templates
cisco.catalystwan.device_templates:
state: present
template_name: "vc8000-device-template"
template_description: "vc8000-device-template"
device_type: vedge-C8000V
device_role: sdwan-edge
general_templates:
- name: "Factory_Default_Cisco_BFD_Template"
subtemplates: "Factory_Default_Cisco_Logging_Template"
- name: "Factory_Default_Cisco_OMP_ipv46_Template"
- name: "Factory_Default_Cisco_Security_Template"
manager_credentials:
<<: *manager_authentication