Note
This module is part of the community.general collection (version 10.7.3).
You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.
To install it, use: ansible-galaxy collection install community.general.
To use it in a playbook, specify: community.general.spectrum_device.
Parameter | Comments |
|---|---|
agentport integer | UDP port used for SNMP discovery. Default: |
community string / required | SNMP community used for device discovery. Required when |
device aliases: host, name string / required | IP address of the device. If a hostname is given, it will be resolved to the IP address. |
landscape string / required | Landscape handle of the SpectroServer to which add or remove the device. |
state string | On On Choices:
|
url aliases: oneclick_url string / required | HTTP, HTTPS URL of the Oneclick server in the form |
url_password aliases: oneclick_password string / required | Oneclick user password. |
url_username aliases: oneclick_user string / required | Oneclick user name. |
use_proxy boolean | If Choices:
|
validate_certs boolean | If Choices:
|
Attribute | Support | Description |
|---|---|---|
check_mode | Support: full | Can run in |
diff_mode | Support: none | Will return details on what has changed (or possibly needs changing in |
Note
- name: Add device to CA Spectrum
local_action:
module: spectrum_device
device: '{{ ansible_host }}'
community: secret
landscape: '0x100000'
oneclick_url: http://oneclick.example.com:8080
oneclick_user: username
oneclick_password: password
state: present
- name: Remove device from CA Spectrum
local_action:
module: spectrum_device
device: '{{ ansible_host }}'
landscape: '{{ landscape_handle }}'
oneclick_url: http://oneclick.example.com:8080
oneclick_user: username
oneclick_password: password
use_proxy: false
state: absent
Common return values are documented here, the following are the fields unique to this module:
Key | Description |
|---|---|
device dictionary | Device data when Returned: success Sample: |
© 2012–2018 Michael DeHaan
© 2018–2025 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/latest/collections/community/general/spectrum_device_module.html