mirror of
https://github.com/logos-messaging/logos-messaging-nim-compose.git
synced 2026-04-03 12:33:34 +00:00
Give more guidance in case the renewal process is not working well
This commit is contained in:
parent
9739695db9
commit
0c3bfcf132
@ -52,6 +52,7 @@ echo "[INFO] Starting renewal loop every ${SLEEP_INTERVAL}..."
|
||||
while true; do
|
||||
echo "[INFO] Checking certificate renewal..."
|
||||
certbot renew --standalone --quiet
|
||||
# certbot renew --standalone ## Use this line instead to debug the output
|
||||
echo "[INFO] Renewal check complete. Sleeping..."
|
||||
sleep "${SLEEP_INTERVAL}"
|
||||
done
|
||||
|
||||
11
run_node.sh
11
run_node.sh
@ -62,19 +62,20 @@ if [ -n "${DOMAIN}" ]; then
|
||||
CERT="${LETSENCRYPT_PATH}/fullchain.pem"
|
||||
KEY="${LETSENCRYPT_PATH}/privkey.pem"
|
||||
|
||||
echo "[INFO] Waiting for a valid TLS certificate for ${DOMAIN}..."
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') [INFO] Waiting for a valid TLS certificate for ${DOMAIN}..."
|
||||
|
||||
while true; do
|
||||
if [ ! -f "${CERT}" ] || [ ! -f "${KEY}" ]; then
|
||||
echo "[INFO] Certificate files not found yet. Waiting..."
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') [INFO] Certificate files not found yet. Waiting..."
|
||||
elif ! openssl x509 -checkend 0 -noout -in "${CERT}" >/dev/null 2>&1; then
|
||||
echo "[WARN] Certificate exists but is expired. Waiting for renewal..."
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') [WARN] Certificate exists but is expired. Waiting for renewal..."
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') [INFO] If that takes more than 15 minutes, please remove --quiet attr in run_certbot.sh so that you can see the reason why renewal is not working."
|
||||
else
|
||||
echo "[INFO] Valid TLS certificate detected."
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') [INFO] Valid TLS certificate detected."
|
||||
break
|
||||
fi
|
||||
|
||||
sleep 5
|
||||
sleep 60
|
||||
done
|
||||
|
||||
WS_SUPPORT="--websocket-support=true"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user