IOS_template - option to ignore errors

Hi,

I am currently testing the functionality of the Ansible network configuration and the scenario i have is that i want to run a generic setup configuration against a number of switches. The configuration may contain syntax that one of the switches does not like - its not important if the command fails (as the particular command varies per switch version) and i would like the command failure to be ignored.

I cannot seem to get this working with the “IOS_template” module which always errors when an incorrect input is detected. I have tried tinkering with the Shell.py and IOS.py files without luck.

I understand i can just cater my templates and variables per switch version/model but maintaining that would be a nightmare.

Does anyone have any suggestions on how this can be achieved?

Thanks,

Amir