google_compute_addresses

List IP addresses in a project. For more information see the official API list and aggregated list documentation.

Example Usage

data "google_compute_addresses" "test" {
    filter = "name:test-*"
}

resource "google_dns_record_set" "frontend" {
  name = "frontend.${google_dns_managed_zone.prod.dns_name}"
  type = "A"
  ttl  = 300

  managed_zone = google_dns_managed_zone.prod.name

  rrdatas = data.google_compute_addresses.test.addresses[*].address
}

resource "google_dns_managed_zone" "prod" {
  name     = "prod-zone"
  dns_name = "prod.mydomain.com."
}

Argument Reference

The following arguments are supported:

Attributes Reference

In addition to the arguments listed above, the following computed attributes are exported:

The addresses block supports: