Closed PieterL75 closed 1 month ago
Additionally, I see that other defined variables are also not usable. I have a 'fact' called 'device_details'. That fact can be used in the connected_endpoints_ethernet_interfaces template, but not in the mlag interface templates
Thank you for reporting this. I can see that the docs mention that mlag_peer
should be available, but all our own examples use the deprecated switch.mlag_peer
, so this is clearly a bug on our side.
We will fix the availability of mlag_peer
, but until then you can use the switch.mlag_peer
. We have moved on to work on 5.0 now, but I will mark this fix for backporting to a 4.10.2 release.
Additionally, I see that other defined variables are also not usable. I have a 'fact' called 'device_details'. That fact can be used in the connected_endpoints_ethernet_interfaces template, but not in the mlag interface templates
I cannot see any explanation for this difference. Please make sure your fact is scoped to all devices and not only set as fact on a subset of devices.
Thank you for taking this and addressing the bug.
I use 4 interface templates on the devices. The ethernet templates can access that variable, but the mlag templates cannot, all in the same device
Thank you for taking this and addressing the bug.
If you have time I would appreciate if you could test the fix in #4429. Note the comment on that PR with instructions on how to download it.
I use 4 interface templates on the devices. The ethernet templates can access that variable, but the mlag templates cannot, all in the same device
That is really weird. The template code is exactly the same, including how it picks up "hostvars" in the templating context. Could it be some inplace update of the data that garbles is before the mlag template runs?
I figured it out.. I started a new fabric, and that one does not have any connected endpoints defined, hence the ethernet template was never used. Turned out I marked out the vars_global_vars section in my ansible.cfg.. that is working now.
I'll see to get that #4429 tested out and let you know
Issue Summary
I have a mlag_port_channel_interfaces (and a mlag_ethernet_interfaces) template to generate the interface descriptions. But when I use {{ mlag_peer }} I get an error during the build playbook. I have to use {{ switch.mlag_peer }}, but seems to be deprecated in 4.x.x
Why is that variable not workign for the mlag_port_channel_interfaces and mlag_ethernet_interfaces interface_descriptions ?
Which component(s) of AVD impacted
eos_designs
How do you run AVD ?
Ansible CLI (with virtual-env or native python)
Steps to reproduce
Relevant log output
Contributing Guide