Disable site if certificate creation fails
This commit is contained in:
parent
6d144044cf
commit
3ba7b5db42
|
@ -254,6 +254,10 @@ function create_letsencrypt_cert {
|
||||||
check_certificates ${SITE_DOMAIN_NAME}
|
check_certificates ${SITE_DOMAIN_NAME}
|
||||||
else
|
else
|
||||||
echo $"Lets Encrypt failed for $SITE_DOMAIN_NAME"
|
echo $"Lets Encrypt failed for $SITE_DOMAIN_NAME"
|
||||||
|
if [ -f /etc/nginx/sites-available/$SITE_DOMAIN_NAME ]; then
|
||||||
|
nginx_dissite $SITE_DOMAIN_NAME
|
||||||
|
systemctl restart nginx
|
||||||
|
fi
|
||||||
exit 682529
|
exit 682529
|
||||||
fi
|
fi
|
||||||
return
|
return
|
||||||
|
|
Loading…
Reference in New Issue