mirror of
https://github.com/rootzoll/raspiblitz.git
synced 2025-02-24 22:58:43 +01:00
fix var names
This commit is contained in:
parent
81d21d772b
commit
26683008da
1 changed files with 3 additions and 3 deletions
|
@ -13,10 +13,10 @@ source /mnt/hdd/raspiblitz.conf
|
|||
# get local IP
|
||||
localip_ALL=$(ip addr | grep 'state UP' -A2 | egrep -v 'docker0' | egrep -i '(*[eth|ens|enp|eno|wlan|wlp][0-9]$)' | tail -n1 | awk '{print $2}' | cut -f1 -d'/')
|
||||
localip_LAN=$(ip addr | grep 'state UP' -A2 | egrep -v 'docker0' | egrep -i '(*[eth][0-9]$)' | tail -n1 | awk '{print $2}' | cut -f1 -d'/')
|
||||
localip="${localIP_ALL}"
|
||||
if [ ${#localIP_LAN} -gt 0 ]; then
|
||||
localip="${localip_ALL}"
|
||||
if [ ${#localip_LAN} -gt 0 ]; then
|
||||
# prefer local IP over LAN over all other if available
|
||||
localip="${localIP_LAN}"
|
||||
localip="${localip_LAN}"
|
||||
fi
|
||||
|
||||
# check for internet connection
|
||||
|
|
Loading…
Add table
Reference in a new issue