Update sites.inc

This commit is contained in:
2023-12-02 13:52:55 -06:00
parent c3ef4e41c4
commit 1cba77a00f

View File

@@ -560,13 +560,10 @@ SITEINFO(){
gosite=${NM_NGINXPATH[${RUN_NODE_TYPE}]}/sites-enabled
declare -A SITELIST
if [ "${gosite}" != "" ]; then
if [ "${SEARCH}" != "0" ]; then
sites=$(find ${gosite}/*${SEARCH,,}*.conf)
else
sites=$(find ${gosite}/*.conf)
fi
[ "${SEARCH}" != "0" ] && siteslist="${gosite}/*${SEARCH,,}*.conf" || siteslist="${gosite}/*.conf"
if [ "${sites}" != "" ]; then
if [ -f ${siteslist} ]; then
sites=$(find ${siteslist})
i=1
for sitefile in ${sites[@]}; do
SITENAME=${sitefile##*/}; SITENAME=${SITENAME/.conf/}