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

Remove Webalizer from system and set awstats as default

Kristan Kenney 7 лет назад
Родитель
Сommit
cfc39dc30b

+ 1 - 4
bin/v-add-web-domain-stats

@@ -2,8 +2,7 @@
 # info: add log analyzer to generate domain statitics
 # options: USER DOMAIN TYPE
 #
-# The call is used for enabling log analyzer system to a domain.  At this time
-# two types of these system is supported - awstats and webalizer. For viewing
+# The call is used for enabling log analyzer system to a domain. For viewing
 # the domain statistics use http://domain.tld/vstats/ link. Access this page
 # is not protected by default. If you want to secure it with passwords you
 # should use v-add-web-domain_stat_auth script.
@@ -74,8 +73,6 @@ if [ "$type" == 'awstats' ]; then
     rm -f /etc/awstats/$type.$domain_idn.conf
     ln -s $HOMEDIR/$user/conf/web/$type.$domain.conf \
         /etc/awstats/$type.$domain_idn.conf
-else
-    mkdir -p /var/lib/webalizer
 fi
 
 

+ 0 - 2
bin/v-change-web-domain-stats

@@ -86,8 +86,6 @@ if [ "$type" == 'awstats' ]; then
     rm -f /etc/awstats/$type.$domain_idn.conf
     ln -s $HOMEDIR/$user/conf/web/$type.$domain.conf \
         /etc/awstats/$type.$domain_idn.conf
-else
-    mkdir -p /var/lib/webalizer
 fi
 
 

+ 0 - 5
bin/v-update-web-domain-stat

@@ -57,10 +57,6 @@ if [ ! -e "$dir" ]; then
 fi
 
 # Defining functions
-build_webalizer() {
-    /usr/bin/webalizer -c $config
-}
-
 build_awstats() {
     if [ -d "/etc/sysconfig" ]; then
         awstats="/usr/share/awstats/wwwroot/cgi-bin/awstats.pl"
@@ -135,7 +131,6 @@ build_awstats() {
 
 # Switching on statistics type
 case $STATS in
-    webalizer) build_webalizer ;;
     awstats) build_awstats ;;
 esac
 

+ 5 - 5
install/hst-install-debian.sh

@@ -30,7 +30,7 @@ if [ "$release" -eq 9 ]; then
     software="nginx apache2 apache2-utils apache2-suexec-custom
         libapache2-mod-ruid2 libapache2-mod-fcgid libapache2-mod-php php
         php-common php-cgi php-mysql php-curl php-pgsql php-imap php-ldap php-apcu
-        awstats webalizer vsftpd proftpd-basic bind9 exim4 exim4-daemon-heavy 
+        awstats vsftpd proftpd-basic bind9 exim4 exim4-daemon-heavy 
         clamav-daemon spamassassin dovecot-imapd dovecot-pop3d roundcube-core net-tools
         roundcube-mysql roundcube-plugins mariadb-client mariadb-common
         mariadb-server postgresql postgresql-contrib phppgadmin phpmyadmin mc
@@ -42,7 +42,7 @@ else
     software="nginx apache2 apache2-utils apache2.2-common
         apache2-suexec-custom libapache2-mod-ruid2
         libapache2-mod-fcgid libapache2-mod-php5 php5 php5-common php5-cgi
-        php5-mysql php5-curl php5-pgsql awstats webalizer vsftpd net-tools
+        php5-mysql php5-curl php5-pgsql awstats vsftpd net-tools
         proftpd-basic bind9 exim4 exim4-daemon-heavy clamav-daemon
         spamassassin dovecot-imapd dovecot-pop3d roundcube-core
         roundcube-mysql roundcube-plugins mariadb-client mariadb-common
@@ -927,7 +927,7 @@ if [ "$apache" = 'yes' ] && [ "$nginx" = 'no' ] ; then
     echo "WEB_PORT='80'" >> $HESTIA/conf/hestia.conf
     echo "WEB_SSL_PORT='443'" >> $HESTIA/conf/hestia.conf
     echo "WEB_SSL='mod_ssl'"  >> $HESTIA/conf/hestia.conf
-    echo "STATS_SYSTEM='webalizer,awstats'" >> $HESTIA/conf/hestia.conf
+    echo "STATS_SYSTEM='awstats'" >> $HESTIA/conf/hestia.conf
 fi
 if [ "$apache" = 'yes' ] && [ "$nginx"  = 'yes' ] ; then
     echo "WEB_SYSTEM='apache2'" >> $HESTIA/conf/hestia.conf
@@ -938,7 +938,7 @@ if [ "$apache" = 'yes' ] && [ "$nginx"  = 'yes' ] ; then
     echo "PROXY_SYSTEM='nginx'" >> $HESTIA/conf/hestia.conf
     echo "PROXY_PORT='80'" >> $HESTIA/conf/hestia.conf
     echo "PROXY_SSL_PORT='443'" >> $HESTIA/conf/hestia.conf
-    echo "STATS_SYSTEM='webalizer,awstats'" >> $HESTIA/conf/hestia.conf
+    echo "STATS_SYSTEM='awstats'" >> $HESTIA/conf/hestia.conf
 fi
 if [ "$apache" = 'no' ] && [ "$nginx"  = 'yes' ]; then
     echo "WEB_SYSTEM='nginx'" >> $HESTIA/conf/hestia.conf
@@ -954,7 +954,7 @@ if [ "$apache" = 'no' ] && [ "$nginx"  = 'yes' ]; then
             echo "WEB_BACKEND='php5-fpm'" >> $HESTIA/conf/hestia.conf
         fi
     fi
-    echo "STATS_SYSTEM='webalizer,awstats'" >> $HESTIA/conf/hestia.conf
+    echo "STATS_SYSTEM='awstats'" >> $HESTIA/conf/hestia.conf
 fi
 
 # FTP stack

+ 4 - 4
install/hst-install-ubuntu.sh

@@ -36,7 +36,7 @@ software="apache2 apache2.2-common apache2-suexec-custom apache2-utils
     ntpdate php php-cgi php-common php-curl phpmyadmin php-mysql php-imap php-ldap
     php-apcu phppgadmin php-pgsql postgresql postgresql-contrib proftpd-basic quota
     roundcube-core roundcube-mysql roundcube-plugins rrdtool rssh spamassassin
-    sudo hestia hestia-nginx hestia-php vim-common vsftpd webalizer whois zip"
+    sudo hestia hestia-nginx hestia-php vim-common vsftpd whois zip"
 
 # Defining help function
 help() {
@@ -906,7 +906,7 @@ if [ "$apache" = 'yes' ] && [ "$nginx" = 'no' ] ; then
     echo "WEB_PORT='80'" >> $HESTIA/conf/hestia.conf
     echo "WEB_SSL_PORT='443'" >> $HESTIA/conf/hestia.conf
     echo "WEB_SSL='mod_ssl'"  >> $HESTIA/conf/hestia.conf
-    echo "STATS_SYSTEM='webalizer,awstats'" >> $HESTIA/conf/hestia.conf
+    echo "STATS_SYSTEM='awstats'" >> $HESTIA/conf/hestia.conf
 fi
 if [ "$apache" = 'yes' ] && [ "$nginx"  = 'yes' ] ; then
     echo "WEB_SYSTEM='apache2'" >> $HESTIA/conf/hestia.conf
@@ -917,7 +917,7 @@ if [ "$apache" = 'yes' ] && [ "$nginx"  = 'yes' ] ; then
     echo "PROXY_SYSTEM='nginx'" >> $HESTIA/conf/hestia.conf
     echo "PROXY_PORT='80'" >> $HESTIA/conf/hestia.conf
     echo "PROXY_SSL_PORT='443'" >> $HESTIA/conf/hestia.conf
-    echo "STATS_SYSTEM='webalizer,awstats'" >> $HESTIA/conf/hestia.conf
+    echo "STATS_SYSTEM='awstats'" >> $HESTIA/conf/hestia.conf
 fi
 if [ "$apache" = 'no' ] && [ "$nginx"  = 'yes' ]; then
     echo "WEB_SYSTEM='nginx'" >> $HESTIA/conf/hestia.conf
@@ -927,7 +927,7 @@ if [ "$apache" = 'no' ] && [ "$nginx"  = 'yes' ]; then
     if [ "$phpfpm" = 'yes' ]; then
         echo "WEB_BACKEND='php-fpm'" >> $HESTIA/conf/hestia.conf
     fi
-    echo "STATS_SYSTEM='webalizer,awstats'" >> $HESTIA/conf/hestia.conf
+    echo "STATS_SYSTEM='awstats'" >> $HESTIA/conf/hestia.conf
 fi
 
 # FTP stack

+ 6 - 0
install/upgrade/0.9.8-28.sh

@@ -206,6 +206,12 @@ for user in `ls /usr/local/hestia/data/users/`; do
     v-rebuild-mail-domains $user
 done
 
+
+# Remove Webalizer and replace it with awstats as default
+echo "(*) Setting awstats as default web statistics backend..."
+apt purge webalizer -y > /dev/null 2>&1
+sed -i "s/STATS_SYSTEM='webalizer,awstats'/STATS_SYSTEM='awstats'/g" $HESTIA/conf/hestia.conf
+
 # Move clamav to proper location - https://goo.gl/zNuM11
 if [ ! -d /usr/local/hestia/web/edit/server/clamav-daemon ]; then
     mv /usr/local/hestia/web/edit/server/clamd /usr/local/web/edit/server/clamav-daemon

+ 3 - 3
test/test_actions.sh

@@ -206,14 +206,14 @@ $cmd > $tmpfile 2>> $tmpfile
 echo_result "WEB: Disabling cgi support" "$?" "$tmpfile" "$cmd"
 
 # Add web domain stats
-cmd="v_add_web_domain_stats $user $domain webalizer"
+cmd="v_add_web_domain_stats $user $domain awstats"
 $cmd > $tmpfile 2>> $tmpfile
-echo_result "WEB: Enabling webalizer" "$?" "$tmpfile" "$cmd"
+echo_result "WEB: Enabling awstats" "$?" "$tmpfile" "$cmd"
 
 # Add web domain stats 
 cmd="v_add_web_domain_stats_user $user $domain test m3g4p4ssw0rd"
 $cmd > $tmpfile 2>> $tmpfile
-echo_result "WEB: Adding webalizer uzer" "$?" "$tmpfile" "$cmd"
+echo_result "WEB: Adding awstats uzer" "$?" "$tmpfile" "$cmd"
 
 # Add web domain nginx
 cmd="v_add_web_domain_nginx $user $domain"

+ 0 - 1
web/inc/i18n/ar.php

@@ -733,7 +733,6 @@ $LANG['ar'] = array(
     'every' => 'كل',
     'Generate' => 'توليد',
 
-    'webalizer' => 'محلل الويب webalizer',
     'awstats' => 'احصائيات الويب awstats',
 
     'Hestia SSL' => 'فيستا SSL',

+ 0 - 1
web/inc/i18n/az.php

@@ -705,7 +705,6 @@ $LANG['az'] = array(
     'every two minutes' => 'hər iki dəqiqdə bir',
     'every' => 'hər',
     'Generate' => 'Yaratmaq',
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
     'Vesta SSL' => 'Vesta SSL',
     'SUBJECT' => 'MÖVZU',

+ 0 - 1
web/inc/i18n/bg.php

@@ -727,7 +727,6 @@ $LANG['bg'] = array(
     'every' => 'всеки',
     'Generate' => 'Генерирай',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/bs.php

@@ -732,7 +732,6 @@ $LANG['bs'] = array(
     'every' => 'svakih',
     'Generate' => 'Generiši',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/cn.php

@@ -741,7 +741,6 @@ $LANG['cn'] = array(
     'every' => '每隔',
     'Generate' => '生成',
 
-    'webalizer' => 'Webalizer',
     'awstats' => 'AWStats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/cz.php

@@ -733,7 +733,6 @@ $LANG['cz'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/da.php

@@ -734,7 +734,6 @@ $LANG['da'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/de.php

@@ -732,7 +732,6 @@ $LANG['de'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/el.php

@@ -734,7 +734,6 @@ $LANG['el'] = array(
     'every' => 'κάθε',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/es.php

@@ -740,7 +740,6 @@ $LANG['es'] = array(
     'every' => 'cada',
     'Generate' => 'Generar',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/fa.php

@@ -708,7 +708,6 @@ $LANG['fa'] = array(
     'every two minutes' => 'هر دو دقیقه',
     'every' => 'هر',
     'Generate' => 'آفریدن',
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
     'Hestia SSL' => 'وستا SSL',
     'SUBJECT' => 'موضوع',

+ 0 - 1
web/inc/i18n/fi.php

@@ -734,7 +734,6 @@ $LANG['fi'] = array(
     'every' => 'every',
     'Generate' => 'Generoi',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/fr.php

@@ -732,7 +732,6 @@ $LANG['fr'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/hu.php

@@ -736,7 +736,6 @@ $LANG['hu'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/id.php

@@ -733,7 +733,6 @@ $LANG['id'] = array(
     'every' => 'setiap',
     'Generate' => 'Hasilkan',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/it.php

@@ -733,7 +733,6 @@ $LANG['it'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/ja.php

@@ -732,7 +732,6 @@ $LANG['ja'] = array(
     'every' => '毎',
     'Generate' => '生成',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/ka.php

@@ -732,7 +732,6 @@ $LANG['ka'] = array(
     'every' => 'ყოველ',
     'Generate' => 'გენერაცია',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/ko.php

@@ -732,7 +732,6 @@ $LANG['ko'] = array(
     'every' => '마다',
     'Generate' => '생성',
 
-    'webalizer' => 'Webalizer',
     'awstats' => 'Awstats',
 
     'Hestia SSL' => 'Hestia 인증서',

+ 0 - 1
web/inc/i18n/nl.php

@@ -736,7 +736,6 @@ $LANG['nl'] = array(
     'every' => 'alle',
     'Generate' => 'Genereer',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/no.php

@@ -733,7 +733,6 @@ $LANG['no'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/pl.php

@@ -733,7 +733,6 @@ $LANG['pl'] = array(
     'every' => 'każdy',
     'Generate' => 'Generuj',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/pt-BR.php

@@ -732,7 +732,6 @@ $LANG['pt-BR'] = array(
     'every' => 'cada',
     'Generate' => 'Gerar',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/pt.php

@@ -732,7 +732,6 @@ $LANG['pt'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/ro.php

@@ -734,7 +734,6 @@ $LANG['ro'] = array(
     'every' => 'fiecare',
     'Generate' => 'Generează',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/ru.php

@@ -735,7 +735,6 @@ $LANG['ru'] = array(
     'every' => 'каждые',
     'Generate' => 'Генерировать',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/se.php

@@ -732,7 +732,6 @@ $LANG['se'] = array(
     'every' => 'every',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/sr.php

@@ -732,7 +732,6 @@ $LANG['sr'] = array(
     'every' => 'svakih',
     'Generate' => 'Generiši',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/th.php

@@ -735,7 +735,6 @@ $LANG['th'] = array(
     'every' => 'ทุก',
     'Generate' => 'สร้าง',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/tr.php

@@ -733,7 +733,6 @@ $LANG['tr'] = array(
     'every' => 'her',
     'Generate' => 'Generate',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/tw.php

@@ -737,7 +737,6 @@ $LANG['tw'] = array(
     'every' => '每',
     'Generate' => '產生',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia 後台 SSL',

+ 0 - 1
web/inc/i18n/ua.php

@@ -733,7 +733,6 @@ $LANG['ua'] = array(
     'every' => 'кожні',
     'Generate' => 'Генерувати',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',

+ 0 - 1
web/inc/i18n/ur.php

@@ -713,7 +713,6 @@ $LANG['ur'] = array(
     'every two minutes'  => 'ہر دو منٹ',
     'every'  => 'ہر کوئی',
     'Generate'  => 'بنائیں',
-    'webalizer'  => 'webalizer',
     'awstats'  => 'awstats',
     'Hestia SSL'  => 'Hestia کی SSL',
     'SUBJECT'  => 'مضمون',

+ 0 - 1
web/inc/i18n/vi.php

@@ -734,7 +734,6 @@ $LANG['vi'] = array(
     'every' => 'mọi',
     'Generate' => 'Tạo',
 
-    'webalizer' => 'webalizer',
     'awstats' => 'awstats',
 
     'Hestia SSL' => 'Hestia SSL',