@@ -167,6 +167,24 @@ if [ "$sumnew" != "$sumold" ]; then
fi
done
+ # now we load the prefix from the hoodfile and set this to br-mesh
+
+ json_load "$(cat /tmp/keyxchangev2data)"
+ json_select network
+ json_get_var prefix ula_prefix
+ # Set $prefix::MAC as IP
+ suffix=$(awk -F: '{ print $1$2":"$3$4":"$5$6 }' /sys/class/net/br-mesh/address)
+ addr=$(echo $prefix | sed -e 's/\//'$suffix'\//')
+ for ip in $(ip -6 addr show dev br-mesh | grep inet6 | grep -v fe80:: | grep -v fdff:: | cut -f6 -d " "); do
+ ip -6 addr del $ip dev br-mesh
+ done
+ if [ -n $(ifconfig br-mesh | grep $addr) ]; then
+ ip -6 addr add $addr dev br-mesh
+ echo "Set ULA adress to br-mesh: $addr"
+ else
+ echo "Address already set"
+ fi
+
echo "Loading wifi"
wifi
this is only a RFC and untested, i need a litte bit feeback about this. Signed-off-by: Christian Dresel <fff@chrisi01.de> --- .../fff/fff-hoods/files/usr/sbin/configurehood | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+)