exoscale_domain_record (Data Source)
Fetch Exoscale DNS Domain Records data.
Corresponding resource: exoscale_domain_record.
Example Usage
data "exoscale_domain" "my_domain" {
name = "my.domain"
}
data "exoscale_domain_record" "my_exoscale_domain_A_records" {
domain = data.exoscale_domain.my_domain.name
filter {
name = "my-host"
record_type = "A"
}
}
data "exoscale_domain_record" "my_exoscale_domain_NS_records" {
domain = data.exoscale_domain.my_domain.name
filter {
content_regex = "ns.*"
}
}
output "my_exoscale_domain_A_records" {
value = join("\n", formatlist(
"%s", data.exoscale_domain_record.my_exoscale_domain_A_records.records.*.name
))
}
output "my_exoscale_domain_NS_records" {
value = join("\n", formatlist(
"%s", data.exoscale_domain_record.my_exoscale_domain_NS_records.records.*.content
))
}Please refer to the examples directory for complete configuration examples.
Schema
Required
domain(String) The exoscale_domain name to match.
Optional
filter(Block, Optional) Filter to apply when looking up domain records. (see below for nested schema)timeouts(Block, Optional) (see below for nested schema)
Read-Only
id(String) The ID of this resource.records(Attributes List) The list of matching records. Structure is documented below. (see below for nested schema)
Nested Schema for filter
Optional:
content_regex(String) A regular expression to match the record content (conflicts withid,nameandrecord_type).id(String) The record ID to match (conflicts withname,record_typeandcontent_regex).name(String) The domain record name to match (conflicts withidandcontent_regex; can be combined withrecord_type).record_type(String) The record type to match (conflicts withidandcontent_regex; can be combined withname).
Nested Schema for timeouts
Optional:
read(String) A string that can be parsed as a duration consisting of numbers and unit suffixes, such as “30s” or “2h45m”. Valid time units are “s” (seconds), “m” (minutes), “h” (hours). Read operations occur during any refresh or planning operation when refresh is enabled.
Nested Schema for records
Read-Only:
content(String) Content of the Recorddomain(String) Domain of the Recordid(String) ID of the Recordname(String) Name of the Recordprio(Number) Priority of the Recordrecord_type(String) Type of the Recordttl(Number) TTL of the Record
Last updated on