You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- name: Obtain list of devices from NetBox
debug:
msg: >
"Device {{ item.value.name }} (ID: {{ item.key }})"
loop: "{{ query('netbox.netbox.nb_lookup', 'virtual-machines',
api_endpoint=netbox_url,
token=netbox_token) }}"
Expected Behavior
Get the list of virtual machines. There is an issue opened in pynetbox repo
Observed Behavior
TASK [roles/netbox_prometheus_role : Obtain list of devices from NetBox] **********************************************************************************************************************************************************************************************
task path: /home/xxxx/dev/prometheus/roles/netbox_prometheus_role/tasks/main.yml:35
exception during Jinja2 execution: Traceback (most recent call last):
File "/usr/lib/python3.10/site-packages/ansible/template/__init__.py", line 831, in _lookup
ran = instance.run(loop_terms, variables=self._available_variables, **kwargs)
File "/home/xxxx/.ansible/collections/ansible_collections/netbox/netbox/plugins/lookup/nb_lookup.py", line 409, in run
netbox = pynetbox.api(
TypeError: Api.__init__() got an unexpected keyword argument 'private_key'
fatal: [xxxx]: FAILED! => {
"msg": "An unhandled exception occurred while running the lookup plugin 'netbox.netbox.nb_lookup'. Error was a <class 'TypeError'>, original message: Api.__init__() got an unexpected keyword argument 'private_key'. Api.__init__() got an unexpected keyword argument 'private_key'"
}
The text was updated successfully, but these errors were encountered:
Ansible NetBox Collection version
v3.10.0
Ansible version
NetBox version
v3.3.5
Python version
3.10
Steps to Reproduce
Expected Behavior
Get the list of virtual machines. There is an issue opened in pynetbox repo
Observed Behavior
The text was updated successfully, but these errors were encountered: