Update nodemgmt-scripts.sh
This commit is contained in:
@@ -799,24 +799,25 @@ NODEUPDATE() {
|
||||
NCMD="ssh -tq root@${nip}"
|
||||
NODE=${NM_HOSTNAMES[${nip}]}[${nip}]
|
||||
c=0; cw=40; spca=''; spc1=${cw}-${#NODE}; until [ $c = ${spc1} ]; do spca="${spca} "; c=`expr $c + 1`; done
|
||||
echo -en "Updating ${NODE}${spca} ~ ${idsCL[LightCyan]}NodeMGMT${idsCL[Default]} : "
|
||||
|
||||
if ! ${NCMD} command -v nodemgmt > /dev/null; then
|
||||
${NCMD} "bash <(curl -sL https://go.scity.us/install-nodemgmt)" >/dev/null 2>&1
|
||||
else
|
||||
${NCMD} "nodemgmt update q" >/dev/null 2>&1
|
||||
fi
|
||||
|
||||
echo -en "${idsCL[Green]}COMPLETE${idsCL[Default]} ~ ${idsCL[LightCyan]}LinUPx${idsCL[Default]} : "
|
||||
|
||||
if ! ${NCMD} command -v runup > /dev/null; then
|
||||
${NCMD} bash <(curl -sL https://go.scity.us/install-linupx) >/dev/null 2>&1
|
||||
else
|
||||
${NCMD} "runup runup" >/dev/null 2>&1
|
||||
fi
|
||||
|
||||
echo -en "${idsCL[Green]}COMPLETE${idsCL[Default]} ~ ${idsCL[LightCyan]}Sync Defaults${idsCL[Default]} : "
|
||||
echo -en "Updating ${NODE}${spca}"
|
||||
|
||||
# echo -en " ~ ${idsCL[LightCyan]}NodeMGMT${idsCL[Default]} : "
|
||||
# if ! ${NCMD} command -v nodemgmt > /dev/null; then
|
||||
# ${NCMD} "bash <(curl -sL https://go.scity.us/install-nodemgmt)" >/dev/null 2>&1
|
||||
# else
|
||||
# ${NCMD} "nodemgmt update q" >/dev/null 2>&1
|
||||
# fi
|
||||
# \ echo -en "${idsCL[Green]}COMPLETE${idsCL[Default]}"
|
||||
#
|
||||
# echo -en " ~ ${idsCL[LightCyan]}LinUPx${idsCL[Default]} : "
|
||||
# if ! ${NCMD} command -v runup > /dev/null; then
|
||||
# ${NCMD} bash <(curl -sL https://go.scity.us/install-linupx) >/dev/null 2>&1
|
||||
# else
|
||||
# ${NCMD} "runup runup" >/dev/null 2>&1
|
||||
# fi
|
||||
# echo -en "${idsCL[Green]}COMPLETE${idsCL[Default]}"
|
||||
|
||||
echo -en " ~ ${idsCL[LightCyan]}Sync Defaults${idsCL[Default]} : "
|
||||
if [ $(ssh -tq root@${nmip} ls -l --time-style=+%s ${NM_FOLDER}/defaults.local.inc | cut -d ' ' -f 6) -ne $(ssh -tq root@${nip} ls -l --time-style=+%s ${NM_FOLDER}/defaults.local.inc | cut -d ' ' -f 6) ]; then
|
||||
ssh -tq root@${nmip} "rsync -az ${NM_FOLDER}/defaults.local.inc root@${nip}:${NM_FOLDER}/" >/dev/null 2>&1
|
||||
echo -e "${idsCL[Green]}SYNCED${idsCL[Default]}"
|
||||
|
||||
Reference in New Issue
Block a user