Changes related to missing awstats icon location block in Nginx vhosts and Awstats configuration on Gentoo
fixes #1228 fixed #1229
This commit is contained in:
@@ -394,6 +394,7 @@ milter_default_action = accept" >> /etc/postfix/main.cf',
|
|||||||
'commands' => Array(
|
'commands' => Array(
|
||||||
'emerge awstats',
|
'emerge awstats',
|
||||||
'sed -i.bak \'s/^DirData/# DirData/\' '.makeCorrectFile($settings['system']['awstats_conf'].'/awstats.model.conf'),
|
'sed -i.bak \'s/^DirData/# DirData/\' '.makeCorrectFile($settings['system']['awstats_conf'].'/awstats.model.conf'),
|
||||||
|
'sed -i.bak \'s|^\\(DirIcons=\\).*$|\\1\\"/awstats-icon\\"|\' '.makeCorrectFile($settings['system']['awstats_conf'].'/awstats.model.conf'),
|
||||||
'# Please make sure you deactivate awstats own cronjob as Froxlor handles that itself',
|
'# Please make sure you deactivate awstats own cronjob as Froxlor handles that itself',
|
||||||
'rm /etc/cron.d/awstats'
|
'rm /etc/cron.d/awstats'
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -698,6 +698,13 @@ class nginx
|
|||||||
$stats_text .= "\t\t" . 'auth_basic_user_file ' . makeCorrectFile($single['usrf']) . ';'."\n";
|
$stats_text .= "\t\t" . 'auth_basic_user_file ' . makeCorrectFile($single['usrf']) . ';'."\n";
|
||||||
$stats_text .= "\t" . '}' . "\n\n";
|
$stats_text .= "\t" . '}' . "\n\n";
|
||||||
|
|
||||||
|
// awstats icons
|
||||||
|
if ($this->settings['system']['awstats_enabled'] == '1') {
|
||||||
|
$stats_text .= "\t" . 'location ~ ^/awstats-icon/(.*)$ {' . "\n";
|
||||||
|
$stats_text .= "\t\t" . 'alias ' . makeCorrectDir($this->settings['system']['awstats_icons']) . '$1;' . "\n";
|
||||||
|
$stats_text .= "\t" . '}' . "\n\n";
|
||||||
|
}
|
||||||
|
|
||||||
return $stats_text;
|
return $stats_text;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user