Replies: 14 comments 5 replies
-
Shudder :-) I was afraid that sooner or later someone would come up with that requirement ... I know of this horrible practice by Cloudflare, which is not permitted for some very good reasons. But having it as a config option won't hurt (much), so it's fine. Let me see if I can squeeze it in before today's release - if I can't you're very welcome to provide a PR. |
Beta Was this translation helpful? Give feedback.
-
OK, squeezing it in quickly failed. It's more complicated than just allowing other record types in Remember to write positive and negative tests and some lines of documentation - nothing fancy, just so the reader knows that the feature is there and they will burn in hell if they ever use it :-) |
Beta Was this translation helpful? Give feedback.
-
Hi That is basically the same thing what Cloudlfare is doing (and it is very usful in some cases). |
Beta Was this translation helpful? Give feedback.
-
I must admit that's where I would draw the line. There is no record type So if you really want |
Beta Was this translation helpful? Give feedback.
-
Generally, no features specific to a particular DNS server implementation will be accepted. Views were an edge-case, because actually they are a BIND specific feature but can be implemented with other servers by running multiple instances. If it's possible to implement specific features using a feature flag, that can be OK, too - the current issue is an example for that, as you can allow it without breaking general compatibility, leaving it up to the user to decide whether it's OK in their specific environment or not. |
Beta Was this translation helpful? Give feedback.
-
That makes totally sense and i completely agree with that statement. i imagined adding the record type ALIAS could be done in a similar way. Apparently that's a different, more complicated story. |
Beta Was this translation helpful? Give feedback.
-
An easy way to find out the set of records that can be supported (that's actually a dynamic set, as it depends directly on the record types supported by
This is dynamic because when (it happened a couple of times over the last years) |
Beta Was this translation helpful? Give feedback.
-
So I think I must correct myself on my absolute dismissal of |
Beta Was this translation helpful? Give feedback.
-
Thanks Peter, i will try. Schöne Grüsse aus Bern |
Beta Was this translation helpful? Give feedback.
-
Your discussion of feature compatibility and RFC compliance made me think about my FR. The feature I requested is easily solved by changing the validation of After thinking about it for a while, maybe my approach was wrong. Maybe the solution is not to change NetBox DNS to somehow work with my DNS service, but to allow it to easily manage RFC compliant data. So I came up with the idea to close this FR. Instead, I would like to propose some kind of new model to manage some kind of autocopy mechanism, where you could define a source record name and matching values will be copied into the destination name as a managed record. For example, What do you think about this? Of course I will formulate a proper FR for this change. |
Beta Was this translation helpful? Give feedback.
-
Hi @alehaa, I've converted your initial FR to a discussion as the issue is starting to get much broader than your original FR. I hope that's OK. In some special cases a The obvious culprit is that you can't create a I like your idea of replicating records to a different zone though, even more so as it also addresses a problem with IPAM DNSsync raised by @phlpr that currently can't be solved in a satisfactory way: #340 (comment). The objective was to create DNS records for IP addresses in multiple zones, and at least for some special cases this could be achieved with "Mirror Zones" (working title, there may be a more suitable name for it). Let me sketch out my first approach to implementing this and tell me if that fits your bill:
What do you think? It's not a small feature, but I think it could be of broader interest and usefulness. |
Beta Was this translation helpful? Give feedback.
-
Filtering is definitely on the list of things that should be added, and it's not a big deal, too - the same mechanism as for IPAM DNSsync filtering will do. Your other use case looks less promising, I'm afraid. To achieve that, you'd need to mirror records from multiple zones to one zone, which introduces a lot of additional problems like collision handling. That would in turn require to validate the records in all target zones before accepting a change to a record in the mirrored zone, which in turn makes validating input a lot more complicated. While this is possible, I must admit I don't see the benefit in a sane ratio to the cost. While your use case is valid, it seems to be a bit exotic (I stand corrected if there are wide-spread uses for it, so everyone please speak up if you disagree), and so I'd go for the other way that's always an option: Write a custom script for it and make it run via button or event hook. My favourite solution for everything too far off-standard. |
Beta Was this translation helpful? Give feedback.
-
When I formulated the feature request described in this discussion, I started working with this plugin and only had a few records to play with and test some scenarios. Now, a few weeks later, I am managing a lot more records and see some problems with my initial proposal. It's all because I want to implement split DNS: we have a lot of internal services and some external ones, but both share the same domain. Now I have some data to check this scenario, let's be pragmatic: replicating the zone with a filter like "record has public flag set" should work fine. In fact, it would save a lot of headaches if we didn't have to think about how to put records in different zones, but just take what's there and select the public records in an external zone copy. So I thought about how to implement this:
|
Beta Was this translation helpful? Give feedback.
-
Just thought I'd chime in - I also have found myself in need of this configuration option. I'm working to sync records from Cloudflare into Netbox, allowing management for both my Internal (PDNS) and External (Cloudflare) DNS from Netbox, using Webhooks + Ansible to call the appropriate APIs. This unfortunately means inputting records that while they exist in Cloudflare, aren't compatible with DNS standards due to Cloudflare's CNAME flattening feature. |
Beta Was this translation helpful? Give feedback.
-
Is your feature request related to a problem? Please describe.
Some DNS providers like Cloudflare allow configuring a
CNAME
for the@
record. Although this is not supported by RFC, they will ensure the domain is resolved correctly.When using this plugin as single source of truth for octoDNS, these records can't be managed. Trying to do so results in the error message:
Describe the solution you'd like
The error message described above originates from
models.Record.clean()
:netbox-plugin-dns/netbox_dns/models/record.py
Lines 786 to 794 in 7e05a4a
I suggest adding a new configuration variable either in the
PLUGIN_CONFIG
or per-view to allowCNAME
records as@
domain name. If set, the code mentioned above should excludeSOA
andNS
records when searching for existing records.Describe alternatives you've considered
A
andAAAA
records can be added manually instead. However, this duplicates management overhead.Additional context
If accepted, I can provide a PR for this feature.
Beta Was this translation helpful? Give feedback.
All reactions