Просмотр исходного кода

Fixes issue with not detecting if allready installed

And rebuild v-update-web-templates instead copying the old file from the package and then to the v-update-web-templates
Jaap Marcus 5 лет назад
Родитель
Сommit
fe5bf53aff
1 измененных файлов с 6 добавлено и 2 удалено
  1. 6 2
      install/upgrade/manual/install_awstats_geoip.sh

+ 6 - 2
install/upgrade/manual/install_awstats_geoip.sh

@@ -18,7 +18,7 @@ source $HESTIA/conf/hestia.conf
 #----------------------------------------------------------#
 
 #check if string already exists
-if grep "geoip" $HESTIA/data/templates/web/awstats/awstats.conf; then 
+if grep "geoip" $HESTIA/data/templates/web/awstats/awstats.tpl; then 
     echo "Plugin allready enabled"
     exit 0
 fi
@@ -32,9 +32,13 @@ if [ -d /etc/awstats ]; then
     perl -MCPAN -f -e "install Geo::IP"
     sed -i '/LoadPlugin=\"geoip GEOIP_STANDARD \/usr\/share\/GeoIP\/GeoIP.dat\"/s/^#//g' /etc/awstats/awstats.conf
     echo "LoadPlugin=\"geoip GEOIP_STANDARD /usr/share/GeoIP/GeoIP.dat\"" >> $HESTIA/data/templates/web/awstats/awstats.tpl
-    $HESTIA/bin/v-update-web-templates "yes"
+    
+    for user in $($BIN/v-list-sys-users plain); do
+        $BIN/v-rebuild-web-domains $user no
+    done
 fi
 
+
 #----------------------------------------------------------#
 #                       Hestia                             #
 #----------------------------------------------------------#