1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2025-06-08 19:00:55 +00:00

Fix Major Crash

This creates a sub-shell for fetching the variable for "DEFAULT_PUBLIC_IP".

This will fix this error while installing:
setup/questions.sh: line 95: DEFAULT_PUBLIC_IP: unbound variable
This commit is contained in:
EliterScripts 2018-12-13 17:44:40 -07:00 committed by GitHub
parent 0d4565e71d
commit 641fedddbd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -92,7 +92,7 @@ if [ -z "${PUBLIC_IP:-}" ]; then
# On the first run, if we got an answer from the Internet then don't
# ask the user.
if [[ -z "$DEFAULT_PUBLIC_IP" && ! -z "$GUESSED_IP" ]]; then
if [[ -z "${DEFAULT_PUBLIC_IP:-}" && ! -z "$GUESSED_IP" ]]; then
PUBLIC_IP=$GUESSED_IP
# Otherwise on the first run at least provide a default.