From be9710f9ead3ce8142d7cff8b76399c4bf04fcc1 Mon Sep 17 00:00:00 2001 From: myvesta <38690722+myvesta@users.noreply.github.com> Date: Tue, 13 Apr 2021 18:25:56 +0200 Subject: [PATCH] Update v-update-letsencrypt-ssl --- bin/v-update-letsencrypt-ssl | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/bin/v-update-letsencrypt-ssl b/bin/v-update-letsencrypt-ssl index aa1f81678..80b071597 100755 --- a/bin/v-update-letsencrypt-ssl +++ b/bin/v-update-letsencrypt-ssl @@ -35,11 +35,10 @@ for user in $($BIN/v-list-users plain |cut -f 1); do fail_counter=$(get_web_counter "$user" "$domain" 'LETSENCRYPT_FAIL_COUNT') - if [[ "$fail_counter" -ge 7 ]]; then + if [[ "$fail_counter" -eq 7 ]]; then if [ "$hostname" = "$domain" ]; then - if [ -z "$SKIP_HOSTNAME_LETSENCRIPT_RENEWING_WARNING" ]; then - send_email_to_admin "LetsEncrypt renewing hostname $hostname" "Warning: hostname $domain failed for LetsEncrypt renewing" - fi + fail_counter=$(alter_web_counter "$user" "$domain" 'LETSENCRYPT_FAIL_COUNT') + send_email_to_admin "LetsEncrypt renewing hostname $hostname" "Warning: hostname $domain failed for LetsEncrypt renewing" fi fi