summaryrefslogtreecommitdiffstats
path: root/testing/openvswitch/ovs-controller.initd
diff options
context:
space:
mode:
authorWilliam Pitcock <nenolod@dereferenced.org>2012-09-26 02:24:03 -0500
committerWilliam Pitcock <nenolod@dereferenced.org>2012-09-26 02:24:03 -0500
commitcdb36ab188ea14ae593f3a2f650540c11a201071 (patch)
treeb30620c190598f1b45207180b33edb139b1f2072 /testing/openvswitch/ovs-controller.initd
parent5bcbfc3c6506772da405c833a726894ce0848705 (diff)
downloadaports-cdb36ab188ea14ae593f3a2f650540c11a201071.tar.bz2
aports-cdb36ab188ea14ae593f3a2f650540c11a201071.tar.xz
testing/openvswitch: new aport
Diffstat (limited to 'testing/openvswitch/ovs-controller.initd')
-rw-r--r--testing/openvswitch/ovs-controller.initd24
1 files changed, 24 insertions, 0 deletions
diff --git a/testing/openvswitch/ovs-controller.initd b/testing/openvswitch/ovs-controller.initd
new file mode 100644
index 000000000..554aebe3f
--- /dev/null
+++ b/testing/openvswitch/ovs-controller.initd
@@ -0,0 +1,24 @@
+#!/sbin/runscript
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/openvswitch/files/ovs-controller,v 1.1 2012/07/18 08:41:29 dev-zero Exp $
+
+depend() {
+ need lo
+}
+
+start() {
+ checkpath -d "/var/run/openvswitch" -m 0750
+
+ ebegin "Starting Open vSwitch OpenFlow controller"
+ start-stop-daemon \
+ --start --quiet --pidfile "/var/run/openvswitch/ovs-controller.pid" \
+ --exec /usr/bin/ovs-controller -- --pidfile --detach --monitor ${OPTIONS} ${METHODS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping Open vSwitch OpenFlow controller"
+ start-stop-daemon --stop --quiet --pidfile "/var/run/openvswitch/ovs-controller.pid"
+ eend $?
+}