Yi Huang | 401f796 | 2014-04-20 11:13:36 -0700 | [diff] [blame] | 1 | #!/bin/bash |
2 | workdir=$1 | ||||
3 | c_ipaddr=$2 | ||||
4 | sudo nfd > $workdir/logs/nfd.log 2>&1 & | ||||
5 | sleep 3 | ||||
6 | faceid=$(nfdc create udp4://$c_ipaddr | grep -Po 'FaceId: .*?,' | sed 's/FaceId: //' | sed 's/,//') | ||||
7 | nfdc add-nexthop ndn:/localhop $faceid |