Update sites.inc

This commit is contained in:
2023-12-02 14:38:44 -06:00
parent 1dcf70cfc6
commit 3e55957a14

View File

@@ -560,9 +560,9 @@ SITEINFO(){
gosite=${NM_NGINXPATH[${RUN_NODE_TYPE}]}/sites-enabled gosite=${NM_NGINXPATH[${RUN_NODE_TYPE}]}/sites-enabled
declare -A SITELIST declare -A SITELIST
if [ "${gosite}" != "" ]; then if [ "${gosite}" != "" ]; then
[ "${SEARCH}" != "0" ] && siteslist=$(find ${gosite}/*${SEARCH,,}*.conf) || siteslist=$(find ${gosite}/*.conf) [ "${SEARCH}" != "0" ] && files=$(shopt -s nullglob dotglob; echo ${gosite}/*${SEARCH,,}*.conf) || files=$(shopt -s nullglob dotglob; echo ${gosite}/*.conf)
echo "HERE: '$siteslist'" if (( ${#files} )); then
if [ "${siteslist}" != "" ]; then [ "${SEARCH}" != "0" ] && siteslist=$(find ${gosite}/*${SEARCH,,}*.conf) || siteslist=$(find ${gosite}/*.conf)
i=1 i=1
for sitefile in ${siteslist[@]}; do for sitefile in ${siteslist[@]}; do
SITENAME=${sitefile##*/}; SITENAME=${SITENAME/.conf/} SITENAME=${sitefile##*/}; SITENAME=${SITENAME/.conf/}