Update dsmon.sh

This commit is contained in:
2023-11-25 16:59:59 -06:00
parent 8e45c3b346
commit 517370e92d

View File

@@ -359,9 +359,11 @@ GETTSIP_NODE(){
hostname=$(hostname -f); hostname=${hostname,,}
([ "${hostname}" == "" ] || [[ "${hostname}" != *".scity"* ]]) && hostname=$(hostname) && hostname="${hostname,,}.ts.scity.us" || hostname=${hostname/.scity/.ts.scity}
echo "Tailscale running, TSIP: ${TSIP}"
echo -en "Updating DNS for '${hostname}' ... "
dyndns=$(/usr/bin/curl -s "https://systems:Dcs9613@ldns.scity.us/nic/update?hostname=${hostname}&myip=${TSIP}")
echo "Done (${dyndns})"
if [ "${NM_PDNS_USER}" != "" ]; then
echo -en "Updating DNS for '${hostname}' ... "
dyndns=$(/usr/bin/curl -s "https://${NM_PDNS_USER}:${NM_PDNS_PASS}@ldns.scity.us/nic/update?hostname=${hostname}&myip=${TSIP}")
echo "Done (${dyndns})"
fi
else
echo "Not running Tailscale"
fi