-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
fix: do not merge CNAME with multiple targets #4856
base: master
Are you sure you want to change the base?
Conversation
|
Welcome @dtuck9! |
Hi @dtuck9. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/ok-to-test |
/retitle fix: do not merge CNAME with multiple targets |
Description
While using the Google Cloud DNS provider, we encountered the following error:
Where
<CNAME DNS Name>
as the DNS Name and<RRData[1].Value>
is the targeted hostname without a trailing.
. After several hours of troubleshooting this failure, we discovered that it was actually a collision with a pre-existing DNS Name, and that the targets had been merged into the sameEndpoint
, where onlyrrdata[0]
had the trailing.
ensured by external-dns.We attempted the following on our end to get around this unexpected behavior in order to trigger the expected 409 error:
.
in our hostname definitions -- this way the 2rrdata
values would at least pass the Cloud DNS API validation for the trailing.
, and then fail with an error that makes more sense (CNAME not allowing more than one value in therrdata
). This however caused a reconciliation loop where external-dns kept deleting and re-adding the records in every batch.external-dns.alpha.kubernetes.io/set-identifier
annotation to prevent the merge in the first place, which would trigger the 409 for the CNAME DNS Name already existing. Unfortunately this also seemed to cause a reconciliation loop where external-dns kept deleting and re-adding the records in every batch.I considered making a change in the Cloud DNS provider to avoid impacting other providers where perhaps this behavior is expected in order to allow different routing policies that are more tightly coupled with the DNS record. However, by the time the endpoint gets into the provider, the context of the duplicate record's resource label has already been lost due to the merge.
We are certainly open to suggestions on how to get around this behavior, or if you'd rather us file an issue and close this PR, that's fine, too.
No relevant user documentation was found.
Checklist