Hack IFS in 'detect-external-ip' script of Docker image to support both Debian and Alpine
This commit is contained in:
parent
484c88ea2a
commit
f2f8796e8c
@ -100,7 +100,8 @@ else
|
||||
}
|
||||
fi
|
||||
|
||||
IFS=$'\n'; for COMMAND in $COMMANDS; do
|
||||
IFS="$(printf '\nx')" && IFS="${IFS%x}"
|
||||
for COMMAND in $COMMANDS; do
|
||||
if IP="$(eval "$COMMAND")" && is_valid_ip "$IP"; then
|
||||
printf '%s' "$IP"
|
||||
exit 0
|
||||
|
||||
Loading…
Reference in New Issue
Block a user