summaryrefslogtreecommitdiffstats
path: root/package/netifd/files/etc/init.d/netifd
blob: e1047e7a81094eb62a3c5af8861f4ed7cbbb00c8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh /etc/rc.common
START=20
PIDFILE=/var/run/netifd.pid

start() {
	stop
	start-stop-daemon -S -b -m -p $PIDFILE -x /sbin/netifd
}

reload() {
	ubus call network reload
}

stop() {
	[ -e "$PIDFILE" ] || return
	start-stop-daemon -K -p $PIDFILE -x /sbin/netifd
	rm -f "$PIDFILE"
}