Hi,
Trying to connect to a MDS switch using the ansible.netcommon.httpapi module in order to just run a gather fact via the nxos module.
Here's how this basic playbook looks like:
---
- hosts: switch1
gather_facts: no
connection: ansible.netcommon.httpapi
collections:
- cisco.nxos
vars:
ansible_user: admin
ansible_password: "{{ passwordinput }}"
ansible_httpapi_port: 8443
tasks:
- name: Gather all legacy facts
cisco.nxos.nxos_facts:
gather_subset: all
The switch returns:
"msg": "[Errno 104] Connection reset by peer"
I have enabled nxapi feature on the switch and so on. Does anyone have an idea what I'm doing wrong here?