aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/lcdproc-dev/lcdproc.inc7
-rw-r--r--config/lcdproc/lcdproc.inc7
-rw-r--r--config/nrpe2/nrpe2.inc2
3 files changed, 13 insertions, 3 deletions
diff --git a/config/lcdproc-dev/lcdproc.inc b/config/lcdproc-dev/lcdproc.inc
index 73827721..fed2e7dc 100644
--- a/config/lcdproc-dev/lcdproc.inc
+++ b/config/lcdproc-dev/lcdproc.inc
@@ -32,7 +32,12 @@
require_once("service-utils.inc");
/* LCDproc */
define('LCDPROC_RCFILE', '/usr/local/etc/rc.d/lcdproc.sh');
- define('LCDPROC_CONFIG','/usr/local/etc/LCDd.conf');
+ $pfs_version = substr(trim(file_get_contents("/etc/version")),0,3);
+ if (($pfs_version == "2.2") && is_dir('/usr/pbi/lcdproc-' . php_uname('m'))) {
+ define('LCDPROC_CONFIG', '/usr/pbi/lcdproc-' . php_uname('m') . '/local/etc/LCDd.conf');
+ } else {
+ define('LCDPROC_CONFIG','/usr/local/etc/LCDd.conf');
+ }
define('LCDPROC_HOST','localhost');
define('LCDPROC_PORT','13666');
define('LCDPROC_SERVICE_NAME','lcdproc');
diff --git a/config/lcdproc/lcdproc.inc b/config/lcdproc/lcdproc.inc
index 760732df..321328bc 100644
--- a/config/lcdproc/lcdproc.inc
+++ b/config/lcdproc/lcdproc.inc
@@ -33,7 +33,12 @@
/* LCDproc */
define('LCDPROC_RCFILE', '/usr/local/etc/rc.d/lcdproc.sh');
define('LCDPROC_CLIENT', '/tmp/lcdclient.sh');
- define('LCDPROC_CONFIG','/usr/local/etc/LCDd.conf');
+ $pfs_version = substr(trim(file_get_contents("/etc/version")),0,3);
+ if (($pfs_version == "2.2") && is_dir('/usr/pbi/lcdproc-' . php_uname('m'))) {
+ define('LCDPROC_CONFIG', '/usr/pbi/lcdproc-' . php_uname('m') . '/local/etc/LCDd.conf');
+ } else {
+ define('LCDPROC_CONFIG','/usr/local/etc/LCDd.conf');
+ }
define('LCDPROC_HOST','localhost');
define('LCDPROC_PORT','13666');
diff --git a/config/nrpe2/nrpe2.inc b/config/nrpe2/nrpe2.inc
index 643cb837..7d541e6b 100644
--- a/config/nrpe2/nrpe2.inc
+++ b/config/nrpe2/nrpe2.inc
@@ -34,7 +34,7 @@ if ($pfs_version == "2.0") {
}
if ($pfs_version == "2.1")
- define('NRPE_BINARY', NRPE_BASE . "sbin/nrpe2");
+ define('NRPE_BINARY', NRPE_BASE . "/sbin/nrpe2");
else
define('NRPE_BINARY', "/usr/local/sbin/nrpe2");