-
Notifications
You must be signed in to change notification settings - Fork 4k
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
aws-route53-targets: LoadBalancerTarget always appends the dualstack
prefix even when not a valid option
#16987
Comments
dualstack
prefix even when not a valid optiondualstack
prefix even when not a valid option
I'm also running into this issue. @epalace510 did you figure out a workaround? In my case I'm creating an NLB-specific version of https://github.com/aws/aws-cdk/blob/v1.134.0/packages/@aws-cdk/aws-route53-targets/lib/load-balancer-target.ts |
Same issue also with CDK v2. |
@larryboymi I wrote a class to do what I needed. It's not my preferred solution, but it unblocked me.
|
@epalace510 yep that's exactly what my class looked like |
I'm facing exactly the same issue. |
This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled. |
What is the problem?
When fixing #6271 with #8747, you enforced that all load balancer targets start with the
dualstack
prefix. Network Load Balancers (NLBs) have 2 IP Address types you can configure, IPv4 or dualstack (this was launched late last year). The default for the property is IPv4, and the CDK definition doesn't even allow for the option to be set. When NLB is set to IPv4, it does not have a dualstack prefix you can route to. This means the generated ARecords don't work; they target a non-existent DNS record.Reproduction Steps
I'm going to leave the class instantiation out, but you can assume this is within a construct.
What did you expect to happen?
I expected a valid Alias ARecord to my NLB.
What actually happened?
The CDK incorrectly prefixed
dualstack
to my NLB DNS name, causing the service to be unreachable.CDK CLI Version
1.125.0
Framework Version
No response
Node.js Version
12
OS
AmazonLinux 2
Language
Typescript
Language Version
No response
Other information
The NLB IPAddressType is a configurable property of the Cfn definition https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-loadbalancer.html#cfn-elasticloadbalancingv2-loadbalancer-ipaddresstype
The text was updated successfully, but these errors were encountered: