From 28717ad3a8c7ad8b4433e1a5364364dfa088e7cd Mon Sep 17 00:00:00 2001 From: David Myers Date: Mon, 13 Dec 2021 15:42:29 -0500 Subject: [PATCH] Make install.sh pass shellcheck (#14353) --- install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install.sh b/install.sh index e16396c..833b277 100644 --- a/install.sh +++ b/install.sh @@ -41,7 +41,7 @@ publicIpFromInterface() { echo "Couldn't find a valid ipv4 address, using the first IP found on the interfaces as the endpoint." DEFAULT_INTERFACE="$(ip -4 route list match default | grep -Eo "dev .*" | awk '{print $2}')" ENDPOINT=$(ip -4 addr sh dev "$DEFAULT_INTERFACE" | grep -w inet | head -n1 | awk '{print $2}' | grep -oE '\b([0-9]{1,3}\.){3}[0-9]{1,3}\b') - export ENDPOINT=$ENDPOINT + export ENDPOINT="${ENDPOINT}" echo "Using ${ENDPOINT} as the endpoint" } @@ -57,7 +57,7 @@ publicIpFromMetadata() { fi if echo "${ENDPOINT}" | grep -oE "\b([0-9]{1,3}\.){3}[0-9]{1,3}\b"; then - export ENDPOINT=$ENDPOINT + export ENDPOINT="${ENDPOINT}" echo "Using ${ENDPOINT} as the endpoint" else publicIpFromInterface