Retrieving a list of all resource managers
Use this definition to retrieve a list of all Lenovo XClarity Administrator resource manager.
Usage
data "lxco_manager" "all" {}
output "all_managers" {
value = data.lxco_manager.all
}
Example
The following example retrieves a list of all resource managers.
terraform {
required_providers {
lxco = {
source = "lenovo.com/xclarity/lxco"
version = "0.1"
}
}
}
provider "lxco" {
host = "192.0.2.0"
# username = ""
# password = ""
}
# Fetch details for all resource managers
data "lxco_manager" "all" {}
# Return details for all resource managers
output "all_managers" {
value = data.lxco_manager.all
}
Inputs
None
Outputs
Name | Type | Description | ||
---|---|---|---|---|
auth_type | String | Authentication type. This is always basic. | ||
hostname | String | Resource manager host name | ||
password | String | Password to use for basic authentication | ||
port | Integer | Resource manager port | ||
type | String | Type of resource manager. This can be one of the following values.
| ||
username | String | Username to use for basic authentication | ||
uuid | String | Resource manager UUID |
The following example is returned if the request is successful.
[{
"auth_type": "basic",
"hostname": "109.0.2.10,"
"port": 443,
"password": "password",
"type": "XClarity Administrator",
"username": "userid",
"uuid": "8D735FCEFBCD49118C68169312166C68"
}]
Give documentation feedback