Update defaults.inc

This commit is contained in:
2025-06-01 20:09:31 -05:00
parent e8fc8212b4
commit 7208496990

View File

@@ -10,18 +10,16 @@ noheader=" gettsip-node get-crontabs get-crontab update report updatenodes runcm
[ "$(ip route | awk '/default/ { print $5 }')" == "link" ] && RNIP=$(ip addr show $(ip route | awk '/1 dev eth0/ { print $5; exit }') | grep "inet" | head -n 1 | awk '/inet/ {print $2}' | cut -d'/' -f1) ||
RNIP=$(ip addr show $(ip route | awk '/default/ { print $5 }') | grep "inet" | head -n 1 | awk '/inet/ {print $2}' | cut -d'/' -f1)
mysqlcmd="mariadb --skip-ssl"
if [ "${TAILSCALE}" == "true" ]; then
mysqlcmd="mariadb --skip-ssl"
if [[ "${RNIP}" == "10.6.1"* ]]; then
mysqlcmd="mysql"
mysql_conn="-h ${NM_SINGLESRVR_IP['MYSQL']}"
elif [ "${TAILSCALE}" == "true" ]; then
nmip=${NM_NODEMANAGER_TS}
mysql_conn="-h 100.100.5.6 -P 3307"
elif [ "${NM_NODEMANAGER}" != "" ]; then
nmip=${NM_NODEMANAGER}
if [[ "${RNIP}" == "10.6.1"* ]]; then
mysqlcmd="mysql"
mysql_conn="-h ${NM_SINGLESRVR_IP['MYSQL']}"
else
mysql_conn="-h ${NM_SINGLESRVR_IP['MYSQL']} -P 3307"
fi
mysql_conn="-h ${NM_SINGLESRVR_IP['MYSQL']} -P 3307"
else
nmip=10.10.10.60
mysql_conn=10.10.1.50