update
This commit is contained in:
10
defaults.inc
10
defaults.inc
@@ -1,5 +1,5 @@
|
||||
#!/usr/bin/env bash
|
||||
VERS='4.14.14-11152023'
|
||||
VERS='4.14.20-11152023'
|
||||
|
||||
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'
|
||||
@@ -114,7 +114,7 @@ NM_LOGFILE=${NM_LOGFOLDER}/logfile
|
||||
NM_WANDNS='wdns.scity.us'
|
||||
NM_LANDNS='ldns.scity.us'
|
||||
|
||||
TSI=$(/sbin/ip link | grep tailscale0) && [ ${#TSI} != 0 ] && RUN_NODE_TSIP=$(/sbin/ip -o -4 addr list tailscale0 | awk '{print $4}' | cut -d/ -f1) || RUN_NODE_TSIP=
|
||||
TSI=$(ip link | grep tailscale0) && [ ${#TSI} != 0 ] && RUN_NODE_TSIP=$(ip -o -4 addr list tailscale0 | awk '{print $4}' | cut -d/ -f1) || RUN_NODE_TSIP=
|
||||
[ "$(ip route | awk '/default/ { print $5 }')" == "link" ] && RNIP=$(ip addr show $(ip route | awk '/1 dev eth0/ { print $5 }') | 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)
|
||||
|
||||
@@ -126,10 +126,10 @@ else
|
||||
var=${NTYPE}_HOSTS[@]
|
||||
RUN_NODE_TYPE=""
|
||||
for nip in "${!var}"; do
|
||||
# echo "${NTYPE} - $nip - ${RNIP} - ${RUN_NODE_TSIP}"
|
||||
if [[ "${RNIP}" == *"${nip}"* ]]; then
|
||||
# echo "${NTYPE} - $nip - ${RUN_NODE_IP} - ${RUN_NODE_TSIP}"
|
||||
if [[ "${RUN_NODE_IP}" == *"${nip}"* ]]; then
|
||||
RUN_NODE_TYPE=${NTYPE};
|
||||
RUN_NODE_IP=${RNIP}
|
||||
RUN_NODE_IP=${RUN_NODE_IP}
|
||||
break 2
|
||||
elif [[ "${RUN_NODE_TSIP}" == *"${nip}"* ]]; then
|
||||
RUN_NODE_TYPE=${NTYPE};
|
||||
|
||||
Reference in New Issue
Block a user