-
Notifications
You must be signed in to change notification settings - Fork 235
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feat(eos_cli_config_gen): add PIM sparse-mode interfaces in doc (#1848)
Co-authored-by: Tony Reddy Goda <[email protected]>
- Loading branch information
Showing
11 changed files
with
112 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
...arista/avd/roles/eos_cli_config_gen/templates/documentation/pim-sparse-mode-interfaces.j2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{# Building list of PIM interfaces - Only IPv4 supported today #} | ||
{% if pim_interfaces | length > 0 %} | ||
|
||
### PIM Sparse Mode enabled interfaces | ||
|
||
| Interface Name | VRF Name | IP Version | DR Priority | Local Interface | | ||
| -------------- | -------- | ---------- | ----------- | --------------- | | ||
{% for interface in pim_interfaces %} | ||
{% set vrf = interface.vrf | arista.avd.default('-') %} | ||
{% set ip_version = "IPv4" %} | ||
{% set dr_priority = interface.pim.ipv4.dr_priority | arista.avd.default('-') %} | ||
{% set local_interface = interface.pim.ipv4.local_interface | arista.avd.default('-') %} | ||
| {{ interface.name }} | {{ vrf }} | {{ ip_version }} | {{ dr_priority }} | {{ local_interface }} | | ||
{% endfor %} | ||
{% endif %} |
25 changes: 25 additions & 0 deletions
25
...ollections/arista/avd/roles/eos_cli_config_gen/templates/documentation/pim-sparse-mode.j2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{# Interfaces #} | ||
{% set pim_interfaces = [] %} | ||
{% for ethernet_interface in ethernet_interfaces | arista.avd.convert_dicts('name') | arista.avd.natural_sort('name') %} | ||
{% if ethernet_interface.pim.ipv4.sparse_mode is arista.avd.defined(true) %} | ||
{% do pim_interfaces.append(ethernet_interface) %} | ||
{% endif %} | ||
{% endfor %} | ||
{% for port_channel_interface in port_channel_interfaces | arista.avd.convert_dicts('name') | arista.avd.natural_sort('name') %} | ||
{% if port_channel_interface.pim.ipv4.sparse_mode is arista.avd.defined(true) %} | ||
{% do pim_interfaces.append(port_channel_interface) %} | ||
{% endif %} | ||
{% endfor %} | ||
{% for vlan_interface in vlan_interfaces | arista.avd.convert_dicts('name') | arista.avd.natural_sort('name') %} | ||
{% if vlan_interface.pim.ipv4.sparse_mode is arista.avd.defined(true) %} | ||
{% do pim_interfaces.append(vlan_interface) %} | ||
{% endif %} | ||
{% endfor %} | ||
{% if router_pim_sparse_mode is arista.avd.defined or pim_interfaces | length > 0 %} | ||
|
||
## PIM Sparse Mode | ||
{## Router pim sparse-mode #} | ||
{% include 'documentation/router-pim-sparse-mode.j2' %} | ||
{## PIM Sparse Mode Interfaces #} | ||
{% include 'documentation/pim-sparse-mode-interfaces.j2' %} | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters