Module: check_mk
Branch: master
Commit: a03e599710e762cec4c943dda4648aba40f0af51
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=a03e599710e762…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Sat Oct 5 18:00:06 2013 +0200
Fixed .f12 helper to support .site
---
livestatus/.f12 | 6 ++++--
web/.f12 | 2 +-
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/livestatus/.f12 b/livestatus/.f12
index 543c461..ac70c7b 100755
--- a/livestatus/.f12
+++ b/livestatus/.f12
@@ -1,4 +1,7 @@
-#!/bin/sh
+#!/bin/bash
+SITE=${SITE:-$(cat ../.site 2>/dev/null || true)}
+SITE=${SITE:-$(omd sites --bare | head -n 1)}
+
set -e
if [ ! -f configure ]; then
aclocal && autoheader && automake -a && autoconf
@@ -11,7 +14,6 @@ fi
make CFLAGS=-g -j 8
-SITE=${SITE:-$(omd sites --bare | head -n 1)}
sudo install src/livestatus.o /omd/versions/default/lib/mk-livestatus/livestatus.o
sudo install -m 755 src/livecheck /omd/versions/default/lib/mk-livestatus
sudo rm -f /omd/versions/default/lib/livecheck
diff --git a/web/.f12 b/web/.f12
index 546ee53..cf8c53b 100644
--- a/web/.f12
+++ b/web/.f12
@@ -1,5 +1,5 @@
#!/bin/bash
-SITE=${SITE:-$(cat ../.site || true)}
+SITE=${SITE:-$(cat ../.site 2>/dev/null || true)}
SITE=${SITE:-$(omd sites --bare | head -n 1)}
sudo rsync --exclude=defaults.py --exclude "*mkevent*" --delete -varx htdocs
plugins /omd/sites/$SITE/share/check_mk/web/
echo "$C files copied"