diff --git a/functions.sh b/functions.sh index 36e7f2b5..5f918d13 100644 --- a/functions.sh +++ b/functions.sh @@ -3,7 +3,7 @@ # (c) Igor Pecovnik # #get ip -showip=$(ifconfig eth0 | awk -F"[: ]+" '/inet addr:/ {print $4}') +showip=$(ifconfig | grep -Eo 'inet (addr:)?([0-9]*\.){3}[0-9]*' | grep -Eo '([0-9]*\.){3}[0-9]*' | grep -v '127.0.0.1') #get architecture if uname -m | grep -i arm > /dev/null; then ARCH=ARM