summaryrefslogtreecommitdiff
blob: b855a33d7173860ebf98da9536b53e9ee8a6f5c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/sbin/runscript
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# $Header: /var/cvsroot/gentoo-x86/net-analyzer/traffic-vis/files/traffic-vis.init.d,v 1.1 2003/10/30 00:17:12 lisa Exp $

opts="depend start stop"

depend() {
	need net
}

start() {
    ebegin "Starting traffic-vis"
    start-stop-daemon --start --quiet --exec /usr/sbin/traffic-collector -- --pid-file /var/run/traffic-collector.pid --interface $TRAFFIC_VIS_INTERFACE --summary-file $TRAFFIC_VIS_FILE $TRAFFIC_VIS_OPTIONS
    eend $? "Failed to start traffic-vis"
}

stop() {
    ebegin "Stopping traffic-vis"
    start-stop-daemon --stop --quiet --pidfile /var/run/traffic-collector.pid
    eend $? "Failed to stop traffic-vis"
}