Use bundled certs to complete the chain

This commit is contained in:
Ken-Håvard Lieng 2016-01-05 20:41:17 +01:00
parent 4b70b9968b
commit 2c26ced716
1 changed files with 2 additions and 2 deletions

View File

@ -58,7 +58,7 @@ func Run(dir, domain, email, port string, onChange func()) (string, string, erro
}
func obtain(client *acme.Client, domain string) error {
cert, errors := client.ObtainCertificate([]string{domain}, false)
cert, errors := client.ObtainCertificate([]string{domain}, true)
if err := errors[domain]; err != nil {
if _, ok := err.(acme.TOSError); ok {
err := client.AgreeToTOS()
@ -112,7 +112,7 @@ func renew(client *acme.Client, domain string) bool {
meta.PrivateKey = key
Renew:
newMeta, err := client.RenewCertificate(meta, false)
newMeta, err := client.RenewCertificate(meta, true)
if err != nil {
if _, ok := err.(acme.TOSError); ok {
err := client.AgreeToTOS()