8

I don't want to only renew the certificates which are going to expire soon. (Whatever soon means). I want to renew all of them to make sure they will be on the same timing in the future.

I cannot find a way to do this with certbot. Any suggestions?

Corporal Touchy
  • 467
  • 2
  • 4
  • 12

3 Answers3

9

Well, certbot -h renew suggests:

renew:

--force-renewal, --renew-by-default If a certificate already exists for the requested domains, renew it now, regardless of whether it is near expiry.

grawity
  • 501,077
2

Somehow the route from letsencrypt to my host was flaky that day and I needed an additional trick. Only some certificates succeeded on the first try and I didn't want to re-request them immediately.

If you want to renew only a specific certificate but really renew that you can use:

certbot renew --cert-name example.com --force-renewal

That saves you retyping all the domains in case you had multiple domains in that cert.

Corporal Touchy
  • 467
  • 2
  • 4
  • 12
1

You can run following command, it will auto-renew the expired certificates:

certbot renew --renew-by-default

At the end of this command you will get output as following:

Congratulations, all renewals succeeded. The following certs have been renewed:
  /etc/letsencrypt/live/a.example.com/fullchain.pem (success)
  /etc/letsencrypt/live/b.example.com/fullchain.pem (success)
  /etc/letsencrypt/live/c.example.com/fullchain.pem (success)
  ...