-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdevicefact_eos.j2
15 lines (12 loc) · 1.1 KB
/
devicefact_eos.j2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# {{inventory_hostname}}
Mgmt-IP: **{{ansible_host}}**<br>
Console: **{{con1| default("n.a.")}}**<br>
Model: **{{ansible_net_model | default(none)}}**<br>
S/N: **{{ansible_net_serialnum | default(none)}}**<br>
Software: **{{ansible_net_version | default(none)}}**<br>
Image: **{{ansible_net_image | default(none)}}**<br>
| Interface | Line | Oper | Description | IPv4 | IPv6 | Neighbor |
| --------- | ---- | ---- | ----------- | ---- | ---- | -------- |
{% for interface in ansible_facts.net_interfaces | sort -%}
| {{ interface }} | {{ ansible_facts.net_interfaces[interface].operstatus }} | {{ ansible_facts.net_interfaces[interface].lineprotocol }} | {{ ansible_facts.net_interfaces[interface].description }} | {{ ansible_facts.net_interfaces[interface].ipv4.address | default("n") }}/{{ ansible_facts.net_interfaces[interface].ipv4.masklen | default("a") }} | {{ ansible_facts.net_interfaces[interface].ipv6.address | default(none) }} {{ ansible_facts.net_interfaces[interface].ipv6.masklen | default(none) }} | {{ ansible_facts.net_neighbors[interface][0].host | default(none) }} |
{% endfor %}