Skip to content

Commit fe5bf53

Browse files
committed
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
1 parent 78866ff commit fe5bf53

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

install/upgrade/manual/install_awstats_geoip.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ source $HESTIA/conf/hestia.conf
1818
#----------------------------------------------------------#
1919

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

41+
3842
#----------------------------------------------------------#
3943
# Hestia #
4044
#----------------------------------------------------------#

0 commit comments

Comments
 (0)