From 5487af6b2ab26bfef7bffdaf89c000b7ebc156e8 Mon Sep 17 00:00:00 2001 From: Julia Kreger Date: Tue, 16 Jun 2015 10:24:28 -0400 Subject: [PATCH] Change simple-init to use a PATH variable Changed simple-init to utilize a PATH variable in order to allow for glean to be executed in the event the operating system places glean in /usr/bin, such as what occurs on CentOS 7. Change-Id: Ibf95fcd7ca368595e8fb3473f25eb0a919726e39 --- elements/simple-init/install.d/simple-init.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/elements/simple-init/install.d/simple-init.sh b/elements/simple-init/install.d/simple-init.sh index cceae2a6f..ad536aa5a 100755 --- a/elements/simple-init/install.d/simple-init.sh +++ b/elements/simple-init/install.d/simple-init.sh @@ -17,6 +17,7 @@ set -eu set -o pipefail +PATH=/usr/local/bin:/bin:/sbin:/usr/bin:/usr/sbin INTERFACE=${1:-} #optional, if not specified configure all available interfaces function config_exists() { @@ -38,7 +39,7 @@ if blkid -t LABEL="config-2" ; then # Mount config drive mkdir -p /mnt/config mount -o mode=0700 $(blkid -t LABEL="config-2" | cut -d ':' -f 1) /mnt/config || true - /usr/local/bin/glean --ssh --skip-network + glean --ssh --skip-network fi if [ -f /usr/bin/dpkg ] ; then @@ -46,7 +47,7 @@ if [ -f /usr/bin/dpkg ] ; then fi if [ -n "$INTERFACE" ]; then - /usr/local/bin/glean --interface $INTERFACE + glean --interface $INTERFACE else - /usr/local/bin/glean + glean fi