Fix ACME TOS
Signed-off-by: Emile Vauge <emile@vauge.com>
This commit is contained in:
parent
0d1ed625a8
commit
6981df3b9a
1 changed files with 14 additions and 0 deletions
14
acme/acme.go
14
acme/acme.go
|
@ -279,6 +279,20 @@ func (a *ACME) CreateConfig(tlsConfig *tls.Config, CheckOnDemandDomain func(doma
|
||||||
// The client has a URL to the current Let's Encrypt Subscriber
|
// The client has a URL to the current Let's Encrypt Subscriber
|
||||||
// Agreement. The user will need to agree to it.
|
// Agreement. The user will need to agree to it.
|
||||||
err = a.client.AgreeToTOS()
|
err = a.client.AgreeToTOS()
|
||||||
|
if err != nil {
|
||||||
|
// Let's Encrypt Subscriber Agreement renew ?
|
||||||
|
reg, err := client.QueryRegistration()
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
account.Registration = reg
|
||||||
|
err = client.AgreeToTOS()
|
||||||
|
if err != nil {
|
||||||
|
log.Errorf("Error sending ACME agreement to TOS: %+v: %s", account, err.Error())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// save account
|
||||||
|
err = a.saveAccount(account)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue