Fix some more $DEFAULT_PUBLIC_IP issues (#1494)

This commit is contained in:
Dean Perry 2018-12-26 20:39:47 +00:00 committed by Joshua Tauberer
parent 71f1c92b9e
commit 31b743b164
1 changed files with 2 additions and 2 deletions

View File

@ -96,12 +96,12 @@ if [ -z "${PUBLIC_IP:-}" ]; then
PUBLIC_IP=$GUESSED_IP
# Otherwise on the first run at least provide a default.
elif [[ -z "$DEFAULT_PUBLIC_IP" ]]; then
elif [[ -z "${DEFAULT_PUBLIC_IP:-}" ]]; then
DEFAULT_PUBLIC_IP=$(get_default_privateip 4)
# On later runs, if the previous value matches the guessed value then
# don't ask the user either.
elif [ "$DEFAULT_PUBLIC_IP" == "$GUESSED_IP" ]; then
elif [ "${DEFAULT_PUBLIC_IP:-}" == "$GUESSED_IP" ]; then
PUBLIC_IP=$GUESSED_IP
fi