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]: Error: PublicZoneVPCAssociation: Attempting to associate public zone #32773

Open
EugenKon opened this issue Jul 31, 2023 · 3 comments
Open
Labels
bug Addresses a defect in current functionality. service/route53 Issues and PRs that pertain to the route53 service.

Comments

@EugenKon
Copy link

Terraform Core Version

1.5.4

AWS Provider Version

5.10.0

Affected Resource(s)

aws_route53_zone

Expected Behavior

No error

Actual Behavior

Same as here #251

Relevant Error/Panic Output Snippet

No response

Terraform Configuration Files

resource "aws_route53_zone" "private-cloud" {
  count         = var.use_dns ? 1 : 0
  name          = var.domain_name
  comment       = "HostedZone created by Route53 Registrar for ${var.project_name}"
  force_destroy = false

  dynamic "vpc" {
    for_each = var.vpc_id

    content {
      vpc_id = vpc.value
    }
  }
}

Steps to Reproduce

I do not have exact steps. What I did: var.use_dns was assigned to false so count is changed from 1 to 0.

Debug Output

No response

Panic Output

No response

Important Factoids

No response

References

No response

Would you like to implement a fix?

None

@EugenKon EugenKon added the bug Addresses a defect in current functionality. label Jul 31, 2023
@github-actions
Copy link

Community Note

Voting for Prioritization

  • Please vote on this issue by adding a 👍 reaction to the original post to help the community and maintainers prioritize this request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

Volunteering to Work on This Issue

  • If you are interested in working on this issue, please leave a comment.
  • If this would be your first contribution, please review the contribution guide.

@github-actions github-actions bot added service/route53 Issues and PRs that pertain to the route53 service. needs-triage Waiting for first response or review from a maintainer. labels Jul 31, 2023
@EugenKon EugenKon changed the title [Bug]: [Bug]: Error: PublicZoneVPCAssociation: Attempting to associate public zone Jul 31, 2023
@justinretzolk justinretzolk removed the needs-triage Waiting for first response or review from a maintainer. label Jul 31, 2023
@EugenKon
Copy link
Author

The plan:

  # module.dns.aws_route53_zone.private-cloud[0] will be updated in-place
  ~ resource "aws_route53_zone" "private-cloud" {
        id                  = "Z0803079GS4S3AQWFY1V"
        name                = "*hidden*"
        tags                = {}
        # (7 unchanged attributes hidden)

      + vpc {
          + vpc_id     = "vpc-0d639d3e779362f6b"
          + vpc_region = (known after apply)
        }
    }

@EugenKon
Copy link
Author

As workaround I manually removed managed by terraform DNS records except NS and SOA
and manually removing hosted zone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Addresses a defect in current functionality. service/route53 Issues and PRs that pertain to the route53 service.
Projects
None yet
Development

No branches or pull requests

2 participants