This commit is contained in:
2023-11-15 08:11:09 -06:00
parent 550bdcf403
commit bbb6fa03ba
2 changed files with 4 additions and 3 deletions

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env bash
VERS='4.14.10-11142023'
VERS='4.14.11-11142023'
noheader=' service status-check nightlyrephp7.3-fpm,new backup report check checkcerts gitea update-nodes copynpmcerts singleservercheck update-dyndns backup-offsitepfsense gui nightlyreview update '
CERT_DAEMON='/snap/bin/certbot'
@@ -26,6 +26,7 @@ if [ -f ${NM_FOLDER}/conf/defaults.local.inc ]; then
declare -A NM_SINGLESRVR_IP
declare -A NM_CERTPATHS
declare -A NM_WWWPATHS
declare -A NM_DYNDNS_LOC
source ${NM_FOLDER}/conf/defaults.local.inc

View File

@@ -506,7 +506,7 @@ UPDATE_DYNDNS(){
esac
shift
done
if [ "${LOCATION,,}" == "mainsite" ] || [ "${LOCATION,,}" == "offsite" ] || [ "${LOCATION,,}" == "kyle" ]; then
if [ "${NM_DYNDNS_LOC}" != "" ] && [ "${NM_DYNDNS_LOC[${LOCATION,,}]}" != "" ]; then
echo
cw_spc=10
echo -e "Checking for DYNDNS update at '${idsCL[Green]}${LOCATION^^}${idsCL[Default]}'"
@@ -530,7 +530,7 @@ UPDATE_DYNDNS(){
if [ ${TESTMODE} -eq 1 ]; then
echo -e "${idsCL[Green]}'${idsCL[LightCyan]}${LOCATION^^}${idsCL[Green]}' WAN IP has changed: ${idsCL[Yellow]}testmode active and will not update records${idsCL[Default]}"
echo -en "\nDYNDNS Credential Test: "
if [ "$(/usr/bin/curl -s "https://${NM_DYNUSER}:${NM_DYNPASS}@wdns.scity.us/nic/update?hostname=sc1.scity.us")" == "good" ]; then
if [ "$(curl -sL "https://${NM_DYNUSER}df:${NM_DYNPASS}@wdns.scity.us/domain/scity.us" | grep "HTTP 403 Error")" == "" ]; then
echo -e "${idsCL[Green]}Pass${idsCL[Default]}"
else
echo -e "${idsCL[LightRed]}Fail${idsCL[Default]}"