Fix for using apex domains with cloudflare DDNS#1072
Merged
fichtner merged 1 commit intoopnsense:masterfrom Dec 17, 2018
cu:fix-cloudflare-ddns-apex-domains
Merged
Fix for using apex domains with cloudflare DDNS#1072fichtner merged 1 commit intoopnsense:masterfrom cu:fix-cloudflare-ddns-apex-domains
fichtner merged 1 commit intoopnsense:masterfrom
cu:fix-cloudflare-ddns-apex-domains
Conversation
When refactoring the Cloudflare DDNS code, I removed a bunch of assumptions but inadvertently added one. The refactored code did not allow for "apex" domain records, records for which there is no hostname, just the bare domain. (Traditionally, these have been referred to as '@' records but with the Cloudflare API, you just hand it the name of the zone.) Ideally there would be a checkbox or something in the UI for this, or even better a way to specify the record and zone separately but in lieu of that, we first try to break the provided string down into hostname and domain portions and look up the zoneId from that. If that fails, we try to look up the zondId using the whole string. And then finally fail if neither return a zone from the API. Hopefully fixes #926 and possibly the issue reported in PR #861.
Member
|
Merged, thanks for working on this! You can ask for testing on the respective tickets using this command: I'll bump the version for the plugin. It should ship in 18.7.10 early in January. Cheers, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When refactoring the Cloudflare DDNS code, I removed a bunch of assumptions
but inadvertently added one. The refactored code did not allow for "apex"
domain records, records for which there is no hostname, just the bare
domain. (Traditionally, these have been referred to as '@' records but
with the Cloudflare API, you just hand it the name of the zone.)
Ideally there would be a checkbox or something in the UI for this, or
even better a way to specify the record and zone separately but in lieu of
that, we first try to break the provided string down into hostname and
domain portions and look up the zoneId from that. If that fails, we try
to look up the zondId using the whole string. And then finally fail if
neither return a zone from the API.
Hopefully fixes #926 and possibly the issue reported in #861 although it'