I need to send commands to 600 network devices (they are Fortinet Access Points) that have SSH enabled. Python is not available on the device, so I need to use something like network_cli.
I’ve tried all the ansible_network_os options (ios, nxos, vyos, eos…), but none work.
Is there a way of sending simple commands to a device without the requirement to specify & verify the device OS?
I don’t care about gathering facts beforehand.
I’ve got a similar issues connecting to a network device running KlasOS. I am not sure which connection type to use to make this work. I’ve tried with the code that @sign@L posted but no luck. In sign@L’s code I see he is using “connection: local” and “ansible_connection=ssh”. Isn’t this the same thing? It picks the connection module to use. Which one is it using in this case; local or ssh? Reading the docs on the “local” connection module is states “This connection plugin allows ansible to execute tasks on the Ansible ‘controller’ instead of on a remote host.”
Can you list the output of you playbook run with -vvv. I wonder how it looks compared to mine. To my understanding if I use local connection module I should be doing something like this in the tasks: