Update sites.inc

This commit is contained in:
2023-12-02 14:10:29 -06:00
parent 4240d9befd
commit 6ba7dd1f1b

View File

@@ -560,7 +560,11 @@ SITEINFO(){
gosite=${NM_NGINXPATH[${RUN_NODE_TYPE}]}/sites-enabled
declare -A SITELIST
if [ "${gosite}" != "" ]; then
if [ -f ${gosite}/*${SEARCH,,}*.conf ]; then
gofor=false
[ "${SEARCH}" != "0" ] && [ -f ${gosite}/*${SEARCH,,}*.conf ] && gofor=true
[ "${SEARCH}" == "0" ] && [ -f ${gosite}/*.conf ] && gofor=true
if [ "${gofor}" == "true" ]; then
[ "${SEARCH}" != "0" ] && sites=$(find ${gosite}/*${SEARCH,,}*.conf) || sites=$(find ${gosite}/*.conf)
i=1
for sitefile in ${sites[@]}; do