-
Notifications
You must be signed in to change notification settings - Fork 0
/
dcnm-query.yml
32 lines (30 loc) · 946 Bytes
/
dcnm-query.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
---
- hosts: dcnm_controllers
gather_facts: false
tasks:
- name: Query All DCNM Networks for provided Fabric
cisco.dcnm.dcnm_network:
fabric: IAD-Fabric
state: query
register: result
- debug:
var: result.response #result.response[1].attach[0].displayName
- name: Query all the switches in the fabric
cisco.dcnm.dcnm_inventory:
fabric: IAD-Fabric
state: query
register: result
- debug:
var: result.response
#ansible_command_timeout: 1000 set in ansible.cfg
#ansible_connect_timeout: 1000 set in ansible.cfg
- name: Query Interfaces
cisco.dcnm.dcnm_interface:
fabric: IAD-Fabric
state: query
config:
- name: Ethernet1/5
switch:
- "10.82.145.224"
#- switch:
# - "10.82.145.224"