Module: check_mk
Branch: master
Commit: 60cedcd76b9c40649afec54d307a0f1c60704488
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=60cedcd76b9c40…
Author: Andreas Umbreit <au(a)mathias-kettner.de>
Date: Tue Oct 23 08:58:04 2018 +0200
FEED-3010: Add tempdir config to agent installation paths rule
The environment variable TEMPDIR can now be set for agent execution
within the ruleset "Installation paths for agent".
The env var will also be set for the start-script of cmk-update-agent
located at /usr/bin. The main reason for this config entry is that
the user can workaround issues with running cmk-update-agent with
the /tmp directory mounted using a noexec-flag.
Change-Id: Iea2f4727b32303e66ed90b382b5b90f43689cda8
---
agents/check_mk_agent.aix | 3 +++
agents/check_mk_agent.freebsd | 2 ++
agents/check_mk_agent.hpux | 3 +++
agents/check_mk_agent.linux | 3 +++
agents/check_mk_agent.macosx | 3 +++
agents/check_mk_agent.netbsd | 3 +++
agents/check_mk_agent.openbsd | 3 +++
agents/check_mk_agent.openwrt | 3 +++
agents/check_mk_agent.solaris | 3 +++
9 files changed, 26 insertions(+)
diff --git a/agents/check_mk_agent.aix b/agents/check_mk_agent.aix
index 810060f..e067df4 100755
--- a/agents/check_mk_agent.aix
+++ b/agents/check_mk_agent.aix
@@ -38,6 +38,9 @@ export MK_LIBDIR=${MK_LIBDIR:-/usr/check_mk/lib}
export MK_CONFDIR=${MK_CONFDIR:-/usr/check_mk/conf}
export MK_VARDIR=${MK_VARDIR:-/tmp/check_mk}
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# All executables in PLUGINSDIR will simply be executed and their
# ouput appended to the output of the agent. Plugins define their own
# sections and must output headers with '<<<' and
'>>>'
diff --git a/agents/check_mk_agent.freebsd b/agents/check_mk_agent.freebsd
index 33e3d8d..e097643 100755
--- a/agents/check_mk_agent.freebsd
+++ b/agents/check_mk_agent.freebsd
@@ -45,6 +45,8 @@ export MK_LIBDIR="/usr/local/lib/check_mk_agent"
export MK_CONFDIR="/etc/check_mk"
export MK_TMPDIR="/var/run/check_mk"
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
# Make sure, locally installed binaries are found
PATH=$PATH:/usr/local/bin:/usr/local/sbin
diff --git a/agents/check_mk_agent.hpux b/agents/check_mk_agent.hpux
index 4fe3ddd..c364db5 100755
--- a/agents/check_mk_agent.hpux
+++ b/agents/check_mk_agent.hpux
@@ -29,6 +29,9 @@ export PATH=$PATH:/usr/sbin:/usr/bin:/usr/contrib/bin
export MK_LIBDIR="/usr/lib/check_mk_agent"
export MK_CONFDIR="/etc/check_mk"
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# All executables in PLUGINSDIR will simply be executed and their
# ouput appended to the output of the agent. Plugins define their own
# sections and must output headers with '<<<' and
'>>>'
diff --git a/agents/check_mk_agent.linux b/agents/check_mk_agent.linux
index 13ee884..d8d92f8 100755
--- a/agents/check_mk_agent.linux
+++ b/agents/check_mk_agent.linux
@@ -32,6 +32,9 @@ export MK_LIBDIR=${MK_LIBDIR:-/usr/lib/check_mk_agent}
export MK_CONFDIR=${MK_CONFDIR:-/etc/check_mk}
export MK_VARDIR=${MK_VARDIR:-/var/lib/check_mk_agent}
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# Provide information about the remote host. That helps when data
# is being sent only once to each remote host.
if [ "$REMOTE_HOST" ] ; then
diff --git a/agents/check_mk_agent.macosx b/agents/check_mk_agent.macosx
index 95e5580..20bcfcc 100755
--- a/agents/check_mk_agent.macosx
+++ b/agents/check_mk_agent.macosx
@@ -34,6 +34,9 @@ unset LANG
export MK_LIBDIR="/to/be/changed"
export MK_CONFDIR="/to/be/changed"
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# close standard input (for security reasons) and stderr
if [ "$1" = -d ]
then
diff --git a/agents/check_mk_agent.netbsd b/agents/check_mk_agent.netbsd
index bf60f7c..25b3b36 100755
--- a/agents/check_mk_agent.netbsd
+++ b/agents/check_mk_agent.netbsd
@@ -37,6 +37,9 @@ unset LANG
export MK_LIBDIR="/change/me/"
export MK_CONFDIR="/change/me"
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# Make sure, locally installed binaries are found
PATH=$PATH:/usr/pkg/bin
diff --git a/agents/check_mk_agent.openbsd b/agents/check_mk_agent.openbsd
index b8263c5..945ff5a 100755
--- a/agents/check_mk_agent.openbsd
+++ b/agents/check_mk_agent.openbsd
@@ -37,6 +37,9 @@ unset LANG
export MK_LIBDIR="/usr/lib/check_mk_agent"
export MK_CONFDIR="/etc"
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# Make sure, locally installed binaries are found
PATH=$PATH:/usr/local/bin
diff --git a/agents/check_mk_agent.openwrt b/agents/check_mk_agent.openwrt
index 8bba808..331b93c 100755
--- a/agents/check_mk_agent.openwrt
+++ b/agents/check_mk_agent.openwrt
@@ -32,6 +32,9 @@ export MK_LIBDIR="/usr/lib/check_mk_agent"
export MK_CONFDIR="/etc/check_mk"
export MK_VARDIR="/var/lib/check_mk_agent"
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# Provide information about the remote host. That helps when data
# is being sent only once to each remote host.
if [ "$REMOTE_HOST" ] ; then
diff --git a/agents/check_mk_agent.solaris b/agents/check_mk_agent.solaris
index 53062c5..5810ee2 100755
--- a/agents/check_mk_agent.solaris
+++ b/agents/check_mk_agent.solaris
@@ -32,6 +32,9 @@ export MK_LIBDIR=${MK_LIBDIR:-/usr/lib/check_mk_agent}
export MK_CONFDIR=${MK_CONFDIR:-/etc/check_mk}
export MK_VARDIR=${MK_VARDIR:-/var/lib/check_mk_agent}
+# Optionally set a tempdir for all subsequent calls
+#export TMPDIR=
+
# All executables in PLUGINSDIR will simply be executed and their
# ouput appended to the output of the agent. Plugins define their own
# sections and must output headers with '<<<' and
'>>>'