Data Sources
zsphere_image_storages
List all Image storages, or query Image storages by exact name match, or query Image storages by name pattern fuzzy match.
zsphere_image_storages (Data Source)
List all Image storages, or query Image storages by exact name match, or query Image storages by name pattern fuzzy match.
Example Usage
data "zsphere_image_storages" "test" {
}
output "zstack_secs" {
value = data.zsphere_image_storages.test
}
# example output:
# zstack_secs = {
# "filter" = tolist([])
# "image_storages" = tolist([
# {
# "available_capacity" = 263827959808
# "name" = "Host-1"
# "state" = "Enabled"
# "status" = "Connected"
# "total_capacity" = 312423686144
# "uuid" = "e3f8b6038e274f0c9354962a78f46177"
# },
# ])
# "name" = tostring(null)
# "name_pattern" = tostring(null)
# }Schema
Optional
filter(Block List) Filter resources based on any field in the schema. For example, to filter by status, usename = "status"andvalues = ["Ready"]. (see below for nested schema)name(String) Exact name for searching Image storage.name_pattern(String) Pattern for fuzzy name search, similar to MySQL LIKE. Use % for multiple characters and _ for exactly one character.
Read-Only
image_storages(Attributes List) List of Image storage entries (see below for nested schema)
Nested Schema for filter
Required:
name(String) Name of the field to filter by (e.g., status, state).values(Set of String) Values to filter by. Multiple values will be treated as an OR condition.
Nested Schema for image_storages
Read-Only:
available_capacity(Number) Available capacity of the Image storage in bytesname(String) Name of the Image storagestate(String) State of the Image storage (Enabled or Disabled)status(String) Readiness status of the Image storagetotal_capacity(Number) Total capacity of the Image storage in bytesuuid(String) UUID identifier of the Image storage