Open
Description
What versions are you using?
required_providers {
thousandeyes = {
source = "thousandeyes/thousandeyes"
version = "2.0.1"
}
}
What did you expect to happen?
Based on the documentation, the DNS record is optional, and it will use ANY if it isn't specified.
What actually happened?
i am getting this message
Error: invalid value for domain (must suffix with record type; check ThousandEyes Developer Reference for more information)
with thousandeyes_dns_trace.dns["www_cisco_com"]
on tests.tf line 27, in resource "thousandeyes_dns_trace" "dns":
domain = each.value.test_url
Terraform code to reproduce the bug
tests.csv
test_resource,test_name,test_url
"app_thousandeyes_com","app.thousandeyes.com","https://app.thousandeyes.com"
"www_lacnic_net","www.lacnic.net","https://www.lacnic.net"
"www_cisco_com","www.cisco.com","https://www.cisco.com"
locals {
tests = csvdecode(file("${path.module}/tests.csv"))
}
resource "thousandeyes_dns_trace" "dns" {
for_each = tomap({ for inst in local.tests : inst.test_resource => inst })
test_name = each.value.test_name
description = "by terraform"
interval = var.test_interval
alerts_enabled = var.alerts
domain = each.value.test_url
dynamic "agents" {
for_each = local.agentId
content {
agent_id = agents.value
}
}
}
Any additional comments or code?
No response
Steps to reproduce the bug
- define TF DNS resource
- add domain only without DNS record
- get error