fix(civo): normalize @ apex record names#6184
fix(civo): normalize @ apex record names#6184cjohnhanson wants to merge 1 commit intokubernetes-sigs:masterfrom
Conversation
|
[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. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
|
|
Welcome @cjohnhanson! |
|
Hi @cjohnhanson. 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. DetailsInstructions 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. |
8d4d93a to
f3b047b
Compare
The Civo DNS API may return "@" as the record name for apex (root) domain records. The provider only handled the empty string case, causing apex records to be unrecognized during reconciliation. This led to repeated "database_dns_record_already_exist" errors on every sync loop as the provider attempted to re-create records it couldn't find. Normalize "@" to "" in both Records() and getRecordID(). Related: kubernetes-sigs#6183 Signed-off-by: Cody J. Hanson <cody@codyjhanson.com>
f3b047b to
f56b462
Compare
ivankatliarchuk
left a comment
There was a problem hiding this comment.
Can you confirm that this PR fixes your issue. Something similar expected #5085 (comment).
| // translated to zone name for the endpoint entry. | ||
| if r.Name == "" { | ||
| // The Civo API may return "@" for apex records instead of "". | ||
| if r.Name == "" || r.Name == "@" { |
There was a problem hiding this comment.
Is this not suppose to be for A and AAAA only based on explanation in the issue?
|
/ok-to-test |
Pull Request Test Coverage Report for Build 21851017585Details
💛 - Coveralls |
What does it do ?
Normalizes
"@"apex record names from the Civo DNS API to empty strings,matching the provider's existing convention for root domain records.
Motivation
The Civo API returns
"@"as the name for apex DNS records. The providerexpected
"", causingRecords()to construct names like@.example.comand
getRecordID()to fail matching existing records. This resulted indatabase_dns_record_already_existerrors on every sync loop.Confirmed via live Civo API calls — all apex records return
"name": "@".Related: #6183
More