پرش به مطلب اصلی

arvancloud_iaas_floating_ips (Data Source)

Lists floating IP addresses in the IaaS platform. Filter by region to retrieve floating IPs in a specific location.

Example Usage

data "arvancloud_iaas_floating_ips" "all" {
# List all floating IPs across all regions
}

data "arvancloud_iaas_floating_ips" "by_region" {
region = "ir-central1"
}

output "all_floating_ips" {
value = data.arvancloud_iaas_floating_ips.all.floating_ips
}

output "active_ips" {
value = [
for ip in data.arvancloud_iaas_floating_ips.by_region.floating_ips :
ip if ip.status == "ACTIVE"
]
}

Schema

Optional

  • region (String) Optional filter to retrieve floating IPs in a specific region (e.g., ir-central1). If not specified, returns floating IPs from all regions.

Read-Only

  • floating_ips (Attributes List) List of floating IP addresses. (see below for nested schema)
  • id (String) Unique identifier for this datasource query.

Nested Schema for floating_ips

Read-Only:

  • created_at (String) Timestamp when the floating IP was created.
  • description (String) Description of the floating IP.
  • fixed_ip_address (String) The fixed (private) IP address associated with this floating IP when attached.
  • floating_ip_address (String) The floating IP address.
  • id (String) Unique identifier for the floating IP.
  • network_id (String) ID of the network this floating IP is associated with.
  • network_name (String) Name of the network this floating IP is associated with.
  • port_id (String) Network port ID associated with this floating IP when attached.
  • region (String) Region where the floating IP is allocated.
  • server_id (String) ID of the server this floating IP is attached to (if any).
  • server_name (String) Name of the server this floating IP is attached to (if any).
  • status (String) Status of the floating IP (e.g., ACTIVE, DOWN).
  • subnet_id (String) ID of the subnet this floating IP is associated with.
  • subnet_name (String) Name of the subnet this floating IP is associated with.