From f2c96a02182804d8055c27037fce41a0e96d1048 Mon Sep 17 00:00:00 2001 From: f Date: Sat, 28 Dec 2024 13:34:53 -0300 Subject: [PATCH] fix: sometimes renewals fail --- certbotd.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/certbotd.sh b/certbotd.sh index 8ec71dd..069af00 100755 --- a/certbotd.sh +++ b/certbotd.sh @@ -112,7 +112,8 @@ case $1 in if test -s "/etc/letsencrypt/renewal/${domain}.conf"; then ok "${domain} already issued" continue - else + # The file exists but it's empty and it was issued before + elif test -f "/etc/letsencrypt/renewal/${domain}.conf" && test -d "/etc/letsencrypt/archive/${domain}"; then ok "${domain} renewal conf was empty, fixing..." other_renewal="$(grep -l -m 1 "^authenticator = webroot$" /etc/letsencrypt/renewal/*.conf | head -1)"