|
|
@ -1,7 +1,7 @@
|
|
|
|
#!/bin/bash -e
|
|
|
|
#!/bin/bash -e
|
|
|
|
|
|
|
|
|
|
|
|
address=$(ip address show dev eth0 scope global | grep -F 'inet ' | perl -pe 's#.*inet (.*?)/.*#$1#')
|
|
|
|
address=$(ip address show dev eth0 scope global | grep -F 'inet ' | perl -pe 's#.*inet (.*?)/.*#$1#')
|
|
|
|
gateway=$(ip route list dev eth0 default | perl -pe 's#.*via ##')
|
|
|
|
gateway=$(ip route list dev eth0 default | perl -pe 's#.*via (.*) #$1#')
|
|
|
|
|
|
|
|
|
|
|
|
# $interface differs from the live system because of different naming schemes
|
|
|
|
# $interface differs from the live system because of different naming schemes
|
|
|
|
# see https://wiki.debian.org/NetworkInterfaceNames for more details
|
|
|
|
# see https://wiki.debian.org/NetworkInterfaceNames for more details
|
|
|
|