Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

netbox_device_bay_template module isn't found #268

Closed
adamwoolhether opened this issue Jul 10, 2020 · 2 comments
Closed

netbox_device_bay_template module isn't found #268

adamwoolhether opened this issue Jul 10, 2020 · 2 comments

Comments

@adamwoolhether
Copy link

adamwoolhether commented Jul 10, 2020

ISSUE TYPE
  • Bug Report
SOFTWARE VERSIONS
Ansible:

ansible 2.9.10
config file = /etc/ansible/ansible.cfg
configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python3.6/site-packages/ansible
executable location = /usr/bin/ansible
python version = 3.6.8 (default, Apr 16 2020, 01:36:27) [GCC 8.3.1 20191121 (Red Hat 8.3.1-5)]

Netbox:

v2.8.6
pynetbox (4.3.3)

Collection:

v0.2.3

SUMMARY

netbox_device_bay_template is not found. I can use netbox_device_bay just fine.

STEPS TO REPRODUCE
---
- name: "PLAY: SETUP MULTI NODE BAYS"
  connection: local
  hosts: localhost
  collections:
    - netbox.netbox

  tasks:
    - name: "TASK 1: SETUP MULTI NODE BAYS"
      netbox_device_bay_template:
        netbox_url: https://1XXX
        netbox_token: XXX
        validate_certs: no
        state: present
        data:
          name: "{{ item.name }}"
          device_type: "{{ item.dev }}"
          description: Node
      loop:
........
EXPECTED RESULTS

A new bay template for the targeted device type

ACTUAL RESULTS

ERROR: couldn't resolve module/action.

ERROR! couldn't resolve module/action 'netbox_device_bay_template'. This often indicates a misspelling, missing collection, or incorrect module path.

The error appears to be in '/ansible/provision/test_bay_temp.yml': line 9, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

  tasks:
    - name: "TASK 1: SETUP MULTI NODE BAYS"
      ^ here
This one looks easy to fix. It seems that there is a value started
with a quote, and the YAML parser is expecting to see the line ended
with the same kind of quote. For instance:

    when: "ok" in result.stdout

Could be written as:

   when: '"ok" in result.stdout'

Or equivalently:

   when: "'ok' in result.stdout"
@toerb
Copy link
Contributor

toerb commented Jul 10, 2020

netbox_device_bay_template is not present in v0.2.3:
https://github.com/netbox-community/ansible_modules/tree/v0.2.3/plugins/modules

It was added 4 days ago in #251 and will be included in v0.2.4.

@adamwoolhether
Copy link
Author

didn't realize that. thank you!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants