Lego: unknown field 'TXTRecords' at installation

Created on 31 Mar 2017  Â·  5Comments  Â·  Source: go-acme/lego

When I try to install via go get -u github.com/xenolf/lego, I get the following error:

$ go get -u github.com/xenolf/lego
# github.com/xenolf/lego/providers/dns/azure
go/src/github.com/xenolf/lego/providers/dns/azure/azure.go:77: unknown field 'TXTRecords' in struct literal of type dns.RecordSetProperties

A few days ago everything went fine on a quite similar machine.
What am I missing?

Most helpful comment

after the error:

$ sed -i 's/TXTRecords/TxtRecords/g' ~/go/src/github.com/xenolf/lego/providers/dns/azure/azure.go
$ go get -u github.com/xenolf/lego

All 5 comments

after the error:

$ sed -i 's/TXTRecords/TxtRecords/g' ~/go/src/github.com/xenolf/lego/providers/dns/azure/azure.go
$ go get -u github.com/xenolf/lego

Is it possible that you guys have an older version of the azure go SDK installed? The field is there in the current master of the SDK.

Last azure SDK changes:
arm/dns/models.go 100644 → 100755

267 -   TXTRecords  *[]TxtRecord        `json:"TXTRecords,omitempty"`
267 +   TxtRecords  *[]TxtRecord        `json:"TXTRecords,omitempty"`

Ah, they made a breaking change upstream recently.

I can confirm that replacing 'TXTRecords' with 'TxtRecords' works. Thanks @asidorov95!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

benjamincudi picture benjamincudi  Â·  3Comments

voltagex picture voltagex  Â·  3Comments

mholt picture mholt  Â·  3Comments

lenovouser picture lenovouser  Â·  5Comments

kuuji picture kuuji  Â·  4Comments