Module: check_mk
Branch: master
Commit: 6b35ce653f27d8cc44f1419ab5a8b9b1c0828095
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=6b35ce653f27d8…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Dec 17 11:01:42 2013 +0100
FIX check_mk -c: Now also rewrites the location of conf.d directory
---
.werks/379 | 10 ++++++++++
ChangeLog | 1 +
modules/check_mk.py | 5 +++++
3 files changed, 16 insertions(+)
diff --git a/.werks/379 b/.werks/379
new file mode 100644
index 0000000..2071d0c
--- /dev/null
+++ b/.werks/379
@@ -0,0 +1,10 @@
+Title: check_mk -c: Now also rewrites the location of conf.d directory
+Level: 1
+Component: core
+Class: fix
+State: unknown
+Version: 1.2.5i1
+Date: 1387274477
+Targetversion: future
+
+
diff --git a/ChangeLog b/ChangeLog
index e5792cf..7dff826 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,7 @@
Core & Setup:
* 0087 FIX: Fixed possible locking issue when using datasource program with long
output...
* 0313 FIX: Avoid duplicate reading of configuration file on --create-rrd...
+ * 0379 FIX: check_mk -c: Now also rewrites the location of conf.d directory
Checks & Agents:
* 0306 esx_vsphere_counters: added missing ramdisk levels sfcbtickets
diff --git a/modules/check_mk.py b/modules/check_mk.py
index 6349fd7..5156294 100755
--- a/modules/check_mk.py
+++ b/modules/check_mk.py
@@ -170,6 +170,11 @@ if __name__ == "__main__":
if not os.path.exists(check_mk_configfile):
sys.stderr.write("Missing configuration file %s.\n" %
check_mk_configfile)
sys.exit(1)
+
+ # Also rewrite the location of the conf.d directory
+ if os.path.exists(check_mk_basedir + "/conf.d"):
+ check_mk_configdir = check_mk_basedir + "/conf.d"
+
else:
sys.stderr.write("Missing argument to option -c.\n")
sys.exit(1)