cmd/devp2p: submit Route53 changes in batches (#20524)

This change works around the 32k RDATA character limit per change
request and fixes several issues in the deployer which prevented it from
working for our production trees.
This commit is contained in:
Felix Lange
2020-01-17 11:32:29 +01:00
committed by GitHub
parent d5acc5ed9e
commit 0af96d2556
4 changed files with 255 additions and 39 deletions

View File

@ -130,9 +130,9 @@ func (c *cloudflareClient) uploadRecords(name string, records map[string]string)
if !exists {
// Entry is unknown, push a new one to Cloudflare.
log.Info(fmt.Sprintf("Creating %s = %q", path, val))
ttl := 1
ttl := rootTTL
if path != name {
ttl = 2147483647 // Max TTL permitted by Cloudflare
ttl = treeNodeTTL // Max TTL permitted by Cloudflare
}
_, err = c.CreateDNSRecord(c.zoneID, cloudflare.DNSRecord{Type: "TXT", Name: path, Content: val, TTL: ttl})
} else if old.Content != val {