blob: 842a9379f3b158da65a252be79e788f299c0d823 [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
tomdefed6f2014-09-29 11:37:02 -070018 sleep 2
tomb41d1ac2014-09-24 01:51:24 -070019end 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