diff --git a/update-from-repo.sh b/update-from-repo.sh index f0f500eb3..e277478d0 100755 --- a/update-from-repo.sh +++ b/update-from-repo.sh @@ -162,10 +162,10 @@ if [[ $EUID -eq 0 ]]; then [[ ! -f "${TEMP}/tarballs/${PROD}-${version}/setup.sh" ]] && \ cp "${TEMP}/setup.sh" "${TEMP}/tarballs/${PROD}-${version}/setup.sh" echo -en "${CYAN}search minserv.conf ... ${NC}" - if [[ -d "/etc/webmin" ]] ; then - MINICONF=`find /etc -name miniserv.conf 2>/dev/null | grep ${PROD} | head -n 1` - else - MINICONF=`find /* -maxdepth 6 -name miniserv.conf 2>/dev/null | grep ${PROD} | head -n 1` + if [[ -f "/etc/webmin/miniserv.conf" ]] ; then + MINICONF=`find /etc -name miniserv.conf 2>/dev/null | grep ${PROD} | head -n 1` + else + MINICONF=`find /* -maxdepth 6 -name miniserv.conf 2>/dev/null | grep ${PROD} | head -n 1` fi MINICONF=`grep env_WEBMIN_CONFIG= ${MINICONF}| sed 's/.*_WEBMIN_CONFIG=//'` echo -e "${ORANGE}found: ${MINICONF}${NC}"