From 5467c41f142542f428e6aa13442c775a465e34ae Mon Sep 17 00:00:00 2001 From: parawizard Date: Wed, 15 Jan 2014 23:20:11 -0500 Subject: Added links to fix pbi problem /w i386 and amd64 Line 154 // Check for pbi install and arch type then create symlinks if (file_exists('/usr/pbi/vnstat-i386')) { exec("ln -s /usr/local/etc/vnstat.conf /usr/pbi/vnstat-i386/etc/vnstat.conf"); } if (file_exists('/usr/pbi/vnstat-amd64')) { exec("ln -s /usr/local/etc/vnstat.conf /usr/pbi/vnstat-amd64/etc/vnstat.conf"); } --- config/vnstat2/vnstat2.inc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'config') diff --git a/config/vnstat2/vnstat2.inc b/config/vnstat2/vnstat2.inc index 9e184758..f0b76989 100644 --- a/config/vnstat2/vnstat2.inc +++ b/config/vnstat2/vnstat2.inc @@ -151,6 +151,9 @@ function vnstat_install_config() { // exec("[ -d /var/db/vnstat ] && mv /var/db/vnstat /conf/vnstat"); exec("[ -d /usr/local/pkg/vnstat ] && mv /usr/local/pkg/vnstat /conf/vnstat"); exec("[ ! -d /conf/vnstat ] && mkdir /conf/vnstat"); +// Check for pbi install and arch type then create symlinks + if (file_exists('/usr/pbi/vnstat-i386')) { exec("ln -s /usr/local/etc/vnstat.conf /usr/pbi/vnstat-i386/etc/vnstat.conf"); } + if (file_exists('/usr/pbi/vnstat-amd64')) { exec("ln -s /usr/local/etc/vnstat.conf /usr/pbi/vnstat-amd64/etc/vnstat.conf"); } // Copy files to web dir exec("[ ! -f /usr/local/www/diag_vnstat2.php ] && cp /usr/local/pkg/diag_vnstat2.abc /usr/local/www/diag_vnstat2.php"); exec("[ ! -f /usr/local/www/diag_vnstat.php ] && cp /usr/local/pkg/diag_vnstat.abc /usr/local/www/diag_vnstat.php"); -- cgit v1.2.3