diff options
author | Alexander Lobodzinski <alobodzinski@users.noreply.github.com> | 2015-09-08 15:19:11 +0300 |
---|---|---|
committer | Alexander Lobodzinski <alobodzinski@users.noreply.github.com> | 2015-09-08 15:19:11 +0300 |
commit | 2d72fe18d3e4f1a7137865c118e9d103699c929c (patch) | |
tree | 71a6dfa17006d69ec88de80ced0768e945d688cb | |
parent | f7ec431a659acae07bcca0feff73888721fa8055 (diff) |
Detect automation with Cfengine 3
-rw-r--r-- | include/tests_tooling | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/include/tests_tooling b/include/tests_tooling index 302a28d9..a8797263 100644 --- a/include/tests_tooling +++ b/include/tests_tooling @@ -20,6 +20,8 @@ PUPPET_MASTER_RUNNING=0 SALT_MASTER_RUNNING=0 SALT_MINION_RUNNING=0 + CF3_MASTER_RUNNING=0 + CF3_MINION_RUNNING=0 # ################################################################################# # @@ -44,6 +46,24 @@ AUTOMATION_TOOL_FOUND=1 Display --indent 4 --text "Found: Cfengine (cfagent)" --result FOUND --color GREEN fi + # Cfengine 3 + CF3_LOCATIONS="/var/cfengine/bin" + for I in ${CF3_LOCATIONS}; do + if [ -d ${I} ]; then + if [ -e ${I}/cf-agent ]; then + logtext "Result: found Cfengine3 agent (cf-agent) in ${I}" + AUTOMATION_TOOL_FOUND=1 + Display --indent 4 --text "Found: Cfengine (agent)" --result FOUND --color GREEN + fi + IsRunning "cf-server" + if [ ${RUNNING} -eq 1 ]; then + logtext "Result: found cfengine server" + CF3_MASTER_RUNNING=1 + report "automation_tool_running[]=cf-server" + Display --indent 4 --text "Found: Cfengine (server)" --result FOUND --color GREEN + fi + fi + done CHEF_LOCATIONS="/opt/chef/bin /opt/chef-server/sv /opt/chefdk/bin" for I in ${CHEF_LOCATIONS}; do |