Comments (4)
Well, let's consider all the possibilities.
- A registrar can be "something" (like ROUTE53, etc) or "none" (the "NONE" provider, meaning "don't update the registrar".
- A DnsProvider can be nil (none specified), "something" (like NAMEDOTCOM or BIND), or "none" (the "NONE" provider, meaning we intentionally don't want to update the zone's records)
That gives us 6 combinations:
R:something D:none
No warning needed. This is a normal "delegated domain" where we control the registrar, but someone else is controlling the zone.
R:none D:none
No warning needed. This is an "inventory only" domain. It is listed in dnsconfig.js just so that "dnscontrol print-ir" lists it. This is done if you keep an inventory of domains that (for example) the company owns but other divisions manage.
R:none D:something
No warning needed. This is a normal "third-party registrar." We control the zone records but someone else is controlling the registrar.
R:something D:something
No warning needed. This is a normal domain. We control the registrar and the zone's records
R:something D:nil
This is the situation that @devblackops had. Because there was no DnsProvider(), no zone records were being updated. It is a legal combination, but it is confusing. Thus, it deserves a warning.
Print: Warning: No DnsProvider() in domain example.com.
R:none D:nil
This combination doesn't make sense. Use the "inventory only" combination instead.
Print: Warning: No DnsProvider() in domain example.com.
The only combinations that don't make sense are the last two. Both should get warnings. To turn off the warnings, add DnsProvider("NONE").
We can be "smart" by only displaying the warning if there are zone records.
To resolve this bug, we should print the warning if len(DomainConfig.DNSProviderNames) == 0 && len(DomainConfig.Records) != 0
from dnscontrol.
interesting, how to add glue records?
from dnscontrol.
@tlimoncelli thanks for this clear explanation. 👏🏻
Certainly interesting! Because I have never thought about the situation R:none D:none
(Include domain names in DNSControl for an overview.) before.
from dnscontrol.
Yeah, the R:none D:none
is something I recently "invented".
Our legal department periodically asks for a list of all the domains we own. I generally give them the output of dnscontrol print-ir | jq -r '.domains[].name'
but then I always have to remember to manually add a couple more domains that aren't maintained by DNSControl.
I know what you're thinking: Tom, there are domains you don't maintain with DNSControl? How dare you???
Yeah, crazy huh? Well, it happens. For example, I can't maintain dnscontrol-azure.com
using DNSControl because it is used in our integration tests. It has to be isolated from everything else or our CI/CD pipeline would clobber our production DNSControl pipeline.
Anyway...
A few months ago I realized I could define this macro:
var REG_THIRDPARTY = NewRegistrar("none");
function INVENTORY_ONLY(name) {
D(name, REG_THIRDPARTY, NO_NS);
}
Now we can list those domains are listed in dnsconfig.js
as:
INVENTORY_ONLY("dnscontrol-azure.com");
INVENTORY_ONLY("example.com");
INVENTORY_ONLY("example2.com");
Now when I run dnscontrol print-ir | jq -r '.domains[].name'
I get the list I want.
from dnscontrol.
Related Issues (20)
- BUNNY_DNS: Error After Zone Creation (The Bunny is Too Fast) HOT 1
- Misleading Error Message when Route53 DelegationSet is full, and a new domain is added HOT 1
- When using Route53 DelegationSets, only get DelegationSet info when needed HOT 1
- Cloudflare api for SVCB HTTPS and DNSKEY record HOT 2
- require json5 file? HOT 6
- DOCS: Domain modifiers code examples HOT 2
- how to set CAA_BUILDER TTL? HOT 2
- VULTR provider: domain not created in web admin causes a panic on preview command HOT 1
- Rackspace Cloud DNS
- miss makezero in slice init HOT 1
- PowerDNS: support for HTTPS/SVCB records HOT 1
- Notifications via Shoutrrr HOT 2
- Porkbun does not work concurrently (`ppreview`) HOT 3
- [axfrdns] Fails to initialize new zones due to servfail HOT 1
- Preview of records if zone doesn't exist yet HOT 4
- DOCS: M365_BUILDER() (Microsoft 365 builder) HOT 7
- [deSEC] nil pointer dereference on http.Client error HOT 5
- ERROR: ERROR: failed parsing domain list from porkbun: json: cannot unmarshal number into Go struct field domainListRecord.domains.securityLock of type string HOT 2
- Nameserver entries are incorrectly modified or created when using AutoDNS HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dnscontrol.