mirror of
https://github.com/go-acme/lego.git
synced 2024-12-23 01:07:23 +02:00
ns1: fix record creation (#2115)
This commit is contained in:
parent
fd6047a1b8
commit
1106ad382f
4
.github/workflows/pr.yml
vendored
4
.github/workflows/pr.yml
vendored
@ -13,8 +13,8 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
GO_VERSION: stable
|
||||
GOLANGCI_LINT_VERSION: ${{vars.GOLANGCI_LINT_VERSION}}
|
||||
HUGO_VERSION: ${{vars.HUGO_VERSION}}
|
||||
GOLANGCI_LINT_VERSION: v1.56.1
|
||||
HUGO_VERSION: 0.117.0
|
||||
CGO_ENABLED: 0
|
||||
LEGO_E2E_TESTS: CI
|
||||
MEMCACHED_HOSTS: localhost:11211
|
||||
|
@ -97,7 +97,9 @@ func (d *DNSProvider) Present(domain, token, keyAuth string) error {
|
||||
if errors.Is(err, rest.ErrRecordMissing) || record == nil {
|
||||
log.Infof("Create a new record for [zone: %s, fqdn: %s, domain: %s]", zone.Zone, info.EffectiveFQDN, domain)
|
||||
|
||||
record = dns.NewRecord(zone.Zone, dns01.UnFqdn(info.EffectiveFQDN), "TXT", nil, nil)
|
||||
// Work through a bug in the NS1 API library that causes 400 Input validation failed (Value None for field '<obj>.filters' is not of type ...)
|
||||
// So the `tags` and `blockedTags` parameters should be initialized to empty.
|
||||
record = dns.NewRecord(zone.Zone, dns01.UnFqdn(info.EffectiveFQDN), "TXT", make(map[string]string), make([]string, 0))
|
||||
record.TTL = d.config.TTL
|
||||
record.Answers = []*dns.Answer{{Rdata: []string{info.Value}}}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user