lenovo.lxca-inventory
Ansible Role: Lenovo LXCA Inventory
This Ansible Role collects inventory data from managed devices using Lenovo xClarity Administrator.
Requirements
Ansible version 2.4.2 or newer (Ansible installation guide)
Python Client for Lenovo xClarity Administrator (LXCA Python Client v2.5.0)
You can install it with:
pip install pylxca
Role Variables
Here are the available variables with their descriptions:
Variable | Description |
---|---|
uuid | Unique identifier for the device |
id | Identifier for the job |
update_list | List of tasks to update |
discover_ip | Specific IP to discover |
Supported Tags
Here are the tags you can use with their descriptions:
tags | Description |
---|---|
chassis | Information about chassis |
cmms | Information about CMMS |
nodes | Information about nodes |
discover | Discovery using SLP |
fans | Information about fans |
fanmuxes | Information about fan multiplexers |
jobs | Information about jobs |
lxcalog | LXCA log |
powersupplies | Information about power supplies |
scalablesystem | Information about scalable systems |
switches | Information about switches |
tasks | Details about tasks and updates |
users | Information about users |
ffdc | FFDC for UUID |
Dependencies
You need to be connected to the Lenovo xClarity Administrator.
Example Playbook
To run an Ansible playbook, use this command:
ansible-playbook -e "lxca_user=<username> lxca_password=<password> lxca_url=https://<lxca-ip>" inventory.yml -vvvv
The -vvvv
option is for verbose output, which helps you see what’s happening during the playbook run.
Here’s an example task in the playbook to get node data from LXCA:
- name: Get nodes data from LXCA
hosts: localhost
connection: local
tasks:
- name: Get nodes
pylxca_module:
login_user: "{{ lxca_user }}"
login_password: "{{ lxca_password }}"
auth_url: "{{ lxca_url }}"
command_options: nodes
register: rslt
tags:
- nodes
Informazioni sul progetto
The lxca-inventory ansible role facilitates collecting inventory data from Lenovo xClarity Adiministrator.
Installa
ansible-galaxy install lenovo.lxca-inventory
Licenza
bsd-3-clause
Download
36.4k
Proprietario
Open source projects from Lenovo