Update nodemgmt-scripts.sh
This commit is contained in:
@@ -511,13 +511,14 @@ DEL-SSL(){
|
||||
DEL_SSL=${1}
|
||||
fi
|
||||
if [ ! -z ${DEL_SSL+x} ] && [ "${DEL_SSL}" != "" ]; then
|
||||
if [ -d /etc/letsencrypt/live/${DEL_SSL} ]"; then
|
||||
echo -e "${idsCL[LightRed]}Deleting the SSL certificates for '${idsCL[Red]}${DEL_SSL}${idsCL[LightRed]}'...${idsCL[Default]}"
|
||||
echo ""
|
||||
|
||||
echo -en "${idsCL[LightRed]}Removing Files and Folders... ${idsCL[Default]}"
|
||||
# rm -rf /etc/letsencrypt/archive/${DEL_SITE}
|
||||
# rm -rf /etc/letsencrypt/live/${DEL_SITE}
|
||||
# rm -f /etc/letsencrypt/renewal/${DEL_SITE}.conf
|
||||
rm -rf /etc/letsencrypt/archive/${DEL_SITE}
|
||||
rm -rf /etc/letsencrypt/live/${DEL_SITE}
|
||||
rm -f /etc/letsencrypt/renewal/${DEL_SITE}.conf
|
||||
echo -e "${idsCL[Green]}OK${idsCL[Default]}"
|
||||
echo ""
|
||||
echo -en "${idsCL[LightYellow]}Waiting for certificate replication between the nodes... ${idsCL[Default]}"
|
||||
@@ -530,7 +531,7 @@ DEL-SSL(){
|
||||
else NCMD="ssh root@${nip}"
|
||||
fi
|
||||
if [ "${NCMD}" != "" ]; then
|
||||
if ${NCMD} "[ -d /etc/letsencrypt/live/${DEL_SITE} ]"; then
|
||||
if ${NCMD} "[ -d /etc/letsencrypt/live/${DEL_SSL} ]"; then
|
||||
tchecked+=false
|
||||
else
|
||||
tchecked+=''
|
||||
@@ -544,6 +545,10 @@ DEL-SSL(){
|
||||
break
|
||||
fi
|
||||
done
|
||||
else
|
||||
echo -e "${idsCL[LightRed]}The SSL files folder for '${idsCL[Red]}${DEL_SSL}${idsCL[LightRed]}' could not be found.${idsCL[Default]}"
|
||||
exit 1
|
||||
fi
|
||||
if [ "${timeout}" != "true" ]; then
|
||||
echo -e "${idsCL[Green]}Completed${idsCL[Default]}"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user