Hi Team,
we are using Ansible playbooks to build traffic tools and have around 500 hosts.
We are heavily relying on templates to generate nftable rules for each hosts which basically contains ip rules (source, target, interface).
Using hostvars in these templates is becoming a costly affair and taking lot of time to run which inturn is causing CPU hog and memory issues.
Is there a way that we can send hostvars or partial output of it (containing ip address of hosts, interfaces) to each host along with the script and then allow the hosts to compute and generate the rules rather than the ansible controller doing all these?
If this method is available please let me know the procedure of sending the same (hostvars).
Please let me know your inputs.
Regards
Aprameya