From fbf1d3390a97da4dfd2f0619644b3f0ad52e58ea Mon Sep 17 00:00:00 2001 From: myvesta <38690722+myvesta@users.noreply.github.com> Date: Thu, 6 Apr 2023 10:24:54 +0200 Subject: [PATCH] Checking for $nonce before step 7, and check for $certificate after step 7 --- bin/v-add-letsencrypt-domain | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/bin/v-add-letsencrypt-domain b/bin/v-add-letsencrypt-domain index 457557f0..7a306ab3 100755 --- a/bin/v-add-letsencrypt-domain +++ b/bin/v-add-letsencrypt-domain @@ -329,6 +329,12 @@ if [[ "$status" -ne 200 ]]; then echo "[$(date)] : EXIT=Let's Encrypt finalize bad status $status" >> /usr/local/vesta/log/letsencrypt.log check_result $E_CONNECT "Let's Encrypt finalize bad status $status" fi + +if [ "$nonce" = "" ]; then + echo "[$(date)] : EXIT=Let's Encrypt 'nonce' is empty after step 6" >> /usr/local/vesta/log/letsencrypt.log + check_result $E_CONNECT "Let's Encrypt 'nonce' is empty after step 6" +fi + if [ "$certificate" = "" ]; then validation="processing" i=1 @@ -351,9 +357,10 @@ if [ "$certificate" = "" ]; then fi done fi -if [ "$nonce" = "" ]; then - echo "[$(date)] : EXIT=Let's Encrypt 'nonce' is empty on step 6" >> /usr/local/vesta/log/letsencrypt.log - check_result $E_CONNECT "Let's Encrypt 'nonce' is empty on step 6" + +if [ "$certificate" = "" ]; then + echo "[$(date)] : EXIT=Let's Encrypt 'certificate' is empty after step 7" >> /usr/local/vesta/log/letsencrypt.log + check_result $E_CONNECT "Let's Encrypt 'certificate' is empty after step 7" fi # Downloading signed certificate / STEP 8