blob: e5cbef29cc3fb6977d475e1a9d529b7b398a7143 [file] [log] [blame]
Alexander Afanasyeva2e423f2014-08-19 15:26:15 -05001description "NDN Autoconfig Server"
2author "Alexander Afanasyev <alexander.afanasyev@ucla.edu>"
3
Alexander Afanasyev2ed95862015-07-23 11:11:53 +08004start on started nfd
5stop on stopping nfd
Alexander Afanasyeva2e423f2014-08-19 15:26:15 -05006
7respawn
8respawn limit unlimited
9
10setuid ndn
11setgid ndn
12
13script
14 FACE_URI=""
Alexander Afanasyev7688d0e2014-09-05 09:52:45 -070015 ROUTABLE_PREFIXES=""
Alexander Afanasyev31206552014-12-18 22:33:28 -080016 ENABLE_DAEMON=false
Alexander Afanasyeva2e423f2014-08-19 15:26:15 -050017 if [ -f /etc/default/ndn-autoconfig-server ]; then
18 . /etc/default/ndn-autoconfig-server
19 fi
20
Alexander Afanasyevf4c49e62014-08-20 11:54:20 -070021 if [ "$FACE_URI" != "" ]; then
Alexander Afanasyeva2e423f2014-08-19 15:26:15 -050022 export HOME=/var/lib/ndn/ndn-autoconfig-server
Alexander Afanasyev7688d0e2014-09-05 09:52:45 -070023 exec /usr/bin/ndn-autoconfig-server $ROUTABLE_PREFIXES $FACE_URI
Alexander Afanasyeva2e423f2014-08-19 15:26:15 -050024 fi
25end script