mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
Emit warning in case of label having multiple TTLs
An RRSet (=label) consisting of multiple records with different TTLs is something not supported by most providers, and should be avoided. Furthermore it is deprecated in rfc2181#section-5.2 Emit a warning for now during validation, eventually turning it into a full-blown error. Fixes #1372
This commit is contained in:
committed by
Tom Limoncelli
parent
1c43d03d89
commit
6e802f2257
@ -573,7 +573,7 @@ func checkLabelHasMultipleTTLs(records []*models.RecordConfig) (errs []error) {
|
||||
for _, r := range records {
|
||||
label := fmt.Sprintf("%s %s", r.GetLabelFQDN(), r.Type)
|
||||
|
||||
// if we have more records for a given label, append their TTLs here
|
||||
// collect the TTLs at this label.
|
||||
m[label] = append(m[label], r.TTL)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user