mirror of
https://github.com/tomeshnet/prototype-cjdns-pi
synced 2025-10-05 23:52:49 +02:00
Better address truncating
This commit is contained in:
@@ -64,8 +64,8 @@ sudo iw dev $mesh_dev set mesh_param mesh_rssi_threshold -65
|
||||
# Make a local-link ip out of yggdrasil ip if $mesh_dev does not have a local-link ip
|
||||
if [ ! -z "$(which yggdrasilctl)" ]; then
|
||||
if [ -z "$(ip addr show dev $mesh_dev | grep inet6\ fe)" ]; then
|
||||
ip=$(yggdrasilctl getSelf | grep "IPv6 address" | awk '{print $3}')
|
||||
ip address add dev $mesh_dev scope link fe80::${ip:20}/64
|
||||
ip="$(sudo yggdrasilctl getSelf | grep "IPv6 address" | awk '{print $3}' | cut -d ":" -f5-8)"
|
||||
ip address add dev $mesh_dev scope link fe80::${ip}/64
|
||||
fi
|
||||
fi
|
||||
|
||||
|
Reference in New Issue
Block a user