diff --git a/conf/explorer/hostname b/conf/explorer/hostname index a3ae4e15..429a5077 100755 --- a/conf/explorer/hostname +++ b/conf/explorer/hostname @@ -1,6 +1,7 @@ #!/bin/sh # # 2010-2011 Nico Schottelius (nico-cdist at schottelius.org) +# 2012 Steven Armstrong (steven-cdist at armstrong.cc) # # This file is part of cdist. # @@ -19,4 +20,6 @@ # # -hostname +if which hostname >/dev/null 2>&1; then + hostname +fi diff --git a/conf/explorer/interfaces b/conf/explorer/interfaces index 76ff32bb..5333b408 100755 --- a/conf/explorer/interfaces +++ b/conf/explorer/interfaces @@ -29,6 +29,11 @@ if which ip >/dev/null 2>&1; then exit 0 fi +if ! which ifconfig >/dev/null 2>&1; then + # no ifconfig, nothing we could do + exit 0 +fi + uname_s="$(uname -s)" REGEXP='s/^(.*)(:[[:space:]]*flags=|Link encap).*/\1/p' diff --git a/conf/explorer/machine b/conf/explorer/machine index 25fc76a9..d295c8e0 100755 --- a/conf/explorer/machine +++ b/conf/explorer/machine @@ -22,4 +22,6 @@ # # -uname -m +if which uname >/dev/null 2>&1; then + uname -m +fi