Fixed issue with getting routing information for L2 devices. Added EnterpriseOSS kit to inventory
This commit is contained in:
parent
dcab91fd63
commit
eee2c8006b
@ -4,4 +4,5 @@ baguleykit:
|
||||
10.10.254.254:
|
||||
10.219.0.1:
|
||||
10.230.0.2:
|
||||
10.11.255.1:
|
||||
10.11.255.1:
|
||||
10.11.200.1:
|
||||
@ -14,23 +14,21 @@
|
||||
- name: Collect device configuration
|
||||
cisco.ios.ios_facts:
|
||||
gather_subset: all
|
||||
register: current_config
|
||||
|
||||
- name: Print device identity info
|
||||
debug:
|
||||
msg: "{{ current_config.ansible_facts.ansible_net_hostname }} is reachable and the OS is {{ current_config.ansible_facts.ansible_net_version }}. SN is {{ current_config.ansible_facts.ansible_net_serialnum }}. Model is {{current_config.ansible_facts.ansible_net_model }}"
|
||||
msg: "{{ ansible_facts.net_hostname }} is reachable and the OS is {{ ansible_facts.net_version }}. SN is {{ ansible_facts.net_serialnum }}. Model is {{ansible_facts.net_model }}"
|
||||
|
||||
- name: Collect interface, routing and device runtime information
|
||||
- name: Collect interface, routing and device runtime information fo L3 devices
|
||||
cisco.ios.ios_command:
|
||||
commands:
|
||||
- show ip interface brief
|
||||
- show interface description
|
||||
- show ip route
|
||||
- '{% if "2960" not in ansible_facts.net_model %} show ip route {% else %} show run | i default-gateway {% endif %}'
|
||||
- show ip arp
|
||||
- show version
|
||||
register: runtime_information
|
||||
|
||||
|
||||
- name: Print interface information
|
||||
debug:
|
||||
var: runtime_information.stdout_lines[0]
|
||||
@ -47,6 +45,6 @@
|
||||
debug:
|
||||
var: runtime_information.stdout_lines[3]
|
||||
|
||||
- name: Print device indormation
|
||||
- name: Print device information
|
||||
debug:
|
||||
var: runtime_information.stdout_lines[4]
|
||||
Loading…
Reference in New Issue
Block a user