blob: 6d80502deae07fc70f0430e3f3434a7a2f945900 [file] [log] [blame]
tom0eaa97f2014-09-22 16:13:06 -07001description "Open Networking Operating System"
2author "ON.Lab"
3
4start on (net-device-up
5 and local-filesystems
6 and runlevel [2345])
7stop on runlevel [016]
8
9console output
10kill timeout 60
11respawn
12
13env LANG=en_US.UTF-8
14env JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64
15
tomb41d1ac2014-09-24 01:51:24 -070016pre-stop script
17 /opt/onos/bin/onos halt 2>/opt/onos/var/stderr.log
18 sleep 3
19end script
20
tom0eaa97f2014-09-22 16:13:06 -070021script
22 [ -f /opt/onos/options ] && . /opt/onos/options
23 start-stop-daemon --signal INT --start --chuid sdn \
tom1a2908c2014-09-23 16:37:39 -070024 --exec /opt/onos/bin/onos-service -- $ONOS_OPTS \
tom0eaa97f2014-09-22 16:13:06 -070025 >/opt/onos/var/stdout.log 2>/opt/onos/var/stderr.log
26end script