Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug report- TXT records seem broken #2058

Open
1 task done
arne21a opened this issue Sep 12, 2024 · 0 comments
Open
1 task done

Bug report- TXT records seem broken #2058

arne21a opened this issue Sep 12, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@arne21a
Copy link
Contributor

arne21a commented Sep 12, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Version of the module you are using

5.7.14

Rover Version

aztfmod/rover:1.4.6-2305.1807

Terraform Version

v1.4.6 on linux_arm64

AzureRM Provider Version

3.75.0

Affected Resource(s)/Data Source(s)

azurerm_dns_txt_record" "txt"

Terraform Configuration Files

dns_zone_records = {
  frontdoor = {
    dns_zone = {
      key = "public_dns"
    }

    records = {
      txt = { //comment after successfull validation
        foobar = {
          name    = "foobar"
          records = {
            text1 = "MS=ms10101010"
          }
        }
      }
    }
  }
}

Expected Behaviour

Create an TXT record with the value of MS=ms10101010

Actual Behaviour

The txt record expects an unspecified data structure containing a value.value expression:

resource "azurerm_dns_txt_record" "txt" {
  for_each = try(var.records.txt, {})

  name                = each.value.name
  zone_name           = var.zone_name
  resource_group_name = var.resource_group_name
  ttl                 = try(each.value.ttl, 300)
  tags                = merge(var.base_tags, try(each.value.tags, {}))

  dynamic "record" {
    for_each = each.value.records


    content {
            value = record.value.value <--

    }
  }
}

I propose to document the required data structure.
I was not able to figure out a working variable, so i will propose a PR to change the expression to work with my configuration.

    content {
            value = record.value <--

    }

Steps to Reproduce

No response

Important Factoids

No response

References

No response

@arne21a arne21a added the bug Something isn't working label Sep 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant