This commit is contained in:
2023-07-03 22:09:41 -05:00
parent f1bf570f44
commit 46c075ebc3
4 changed files with 106 additions and 93 deletions

View File

@@ -342,9 +342,11 @@ SERVICE(){
if [ "${checkhost}" != "false" ]; then
#$NCMD mount -a > /dev/null 2>&1
if [ "${3}" != "q" ]; then
if [[ "${NCHOSTS}" == *"${nip}"* ]]; then
# if [[ "${NCHOSTS}" == *"${nip}"* ]]; then
if [[ " ${NC_HOSTS[*]} " =~ " ${nip} " ]]; then
mntpath="/mnt/Nextcloud-Data"
elif [[ "${WEBHOSTS}" == *"${nip}"* ]]; then
# elif [[ "${WEBHOSTS}" == *"${nip}"* ]]; then
elif [[ " ${WEB_HOSTS[*]} " =~ " ${nip} " ]]; then
mntpath="/mnt/web-data"
fi
${NCMD} "test -e ${mntpath}/mounted"
@@ -417,7 +419,7 @@ SERVICE(){
# fi
if [ "${3}" != "q" ]; then
if [ "${NM_SERVICES[${1}]}" = "" ]; then
if [ "${NM_SERVICE_DESC[${1}]}" = "" ]; then
echo -e "${idsCL[Red]}(${1}) is not an allowed service.${idsCL[Default]}"
exit 1
fi
@@ -432,7 +434,7 @@ SERVICE(){
fi
echo
echo -e "${idsCL[LightGreen]}[[ ${NM_SERVICES[${1}]} ${NM_SRVCOPTS[${2}]}ing ]]${idsCL[Default]}"
echo -e "${idsCL[LightGreen]}[[ ${NM_SERVICE_DESC[${1}]} ${NM_SRVCOPTS[${2}]}ing ]]${idsCL[Default]}"
echo -e "${idsCL[LightGreen]}-------------------------------------------${idsCL[Default]}"
fi
@@ -577,7 +579,7 @@ SERVICE(){
if [ "${3}" != "q" ]; then
echo
echo -e "${idsCL[Green]}${NM_SERVICES[${1}]} has been ${NM_SRVCOPTS[${2}]}ed${idsCL[Default]}"
echo -e "${idsCL[Green]}${NM_SERVICE_DESC[${1}]} has been ${NM_SRVCOPTS[${2}]}ed${idsCL[Default]}"
echo
fi
}
@@ -1028,8 +1030,8 @@ DOWNLIST(){
host=${ditem%%~*}
item=${ditem#*~}
if [[ $ditem == *"~"* ]] && [ "${NM_SERVICES[${item}]}" != "" ]; then
itemname=${NM_SERVICES[${item}]}
if [[ $ditem == *"~"* ]] && [ "${NM_SERVICE_DESC[${item}]}" != "" ]; then
itemname=${NM_SERVICE_DESC[${item}]}
elif [[ $ditem == *"~"* ]] && [ "${NM_DOCKERS[${item}]}" != "" ]; then
itemname="${NM_DOCKERS[${item}]} (docker)"
elif [[ $ditem == *"~"* ]] && [ "${REPL_DESC[${item}]}" != "" ]; then