Skip to content

Commit

Permalink
in case of certificate renewing error, print also expiring date
Browse files Browse the repository at this point in the history
  • Loading branch information
rejetto committed Sep 29, 2024
1 parent 9016f4a commit 2f95654
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/acme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,6 @@ const renewCert = debounceAsync(async () => {
if (now > new Date(cert.validFrom) && now < validTo && validTo.getTime() - now.getTime() >= 30 * DAY)
return console.log("certificate still good")
await makeCert(domain, acmeEmail.get(), altNames)
.catch(e => console.log("error renewing certificate: ", String(e.message || e)))
.catch(e => console.log(`error renewing certificate, expiring ${validTo.toLocaleString()}: `, String(e.message || e)))
}, { retain: DAY, retainFailure: HOUR })

0 comments on commit 2f95654

Please sign in to comment.