Setting static ip address
This commit is contained in:
parent
34003a4de8
commit
6932df7fdb
|
@ -1481,8 +1481,9 @@ Enter a static local IP address for this system.\n\nIt will typically be ${IPv4_
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if [[ "$NEW_STATIC_GATEWAY" == *"."* && "$NEW_STATIC_IP" == *"."* ]]; then
|
if [[ "$NEW_STATIC_GATEWAY" == *"."* && "$NEW_STATIC_IP" == *"."* ]]; then
|
||||||
ip_addresses_have_changed=
|
ip_addresses_have_changed=1
|
||||||
if [ -f /etc/network/interfaces.d/static ]; then
|
if [ -f /etc/network/interfaces.d/static ]; then
|
||||||
|
ip_addresses_have_changed=
|
||||||
if ! grep -q "address ${NEW_STATIC_IP}" /etc/network/interfaces.d/static; then
|
if ! grep -q "address ${NEW_STATIC_IP}" /etc/network/interfaces.d/static; then
|
||||||
ip_addresses_have_changed=1
|
ip_addresses_have_changed=1
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue