* linting
* Fix adding-new-rtypes.md to include validation
* BIND: improve docs wrt SOA records, get-zones
This commit is contained in:
Tom Limoncelli 2020-02-23 14:47:14 -05:00 committed by GitHub
parent 9812ecd9ff
commit 772ca4e7dd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 16 additions and 2 deletions

View file

@ -46,7 +46,16 @@ var BIND = NewDnsProvider('bind', 'BIND', {
})
{% endhighlight %}
## SOA Records
# FYI: get-zones
When used with "get-zones", specifying "all" scans the directory for
any files named `*.zone` and assumes they are zone files.
```
dnscontrol get-zones --format=nameonly - BIND all
```
# FYI: SOA Records
DNSControl assumes that SOA records are managed by the provider. Most
providers simply generate the SOA record for you and do not permit you

View file

@ -53,6 +53,11 @@ a minimum.
* Add the capability to the file `dnscontrol/providers/capabilities.go` (look for `CanUseAlias` and add
it to the end of the list.)
* Add this feature to the feature matrix in `dnscontrol/build/generate/featureMatrix.go` (Add it to the variable `matrix` then add it later in the file with a `setCap()` statement.
* Add the capability to the list of features that zones are validated
against (i.e. if you want dnscontrol to report an error if this
feature is used with a DNS provider that doesn't support it). That's
in the `checkProviderCapabilities` function in
`pkg/normalize/validate.go`.
* Mark the `bind` provider as supporting this record type by updating `dnscontrol/providers/bind/bindProvider.go` (look for `providers.CanUse` and you'll see what to do).
## Step 3: Add a helper function

View file

@ -36,7 +36,7 @@ type HXRecord struct {
}
// GetZoneRecords gets the records of a zone and returns them in RecordConfig format.
func (client *HXClient) GetZoneRecords(domain string) (models.Records, error) {
func (n *HXClient) GetZoneRecords(domain string) (models.Records, error) {
return nil, fmt.Errorf("not implemented")
// This enables the get-zones subcommand.
// Implement this by extracting the code from GetDomainCorrections into