- Use netifd no_proto_task for notifying that xl2tpd does not have a protocol task running. - Use procd for xl2tpd service management. - Refreshed 2xx patches to - Prevent leftover regular type control result file. - Allow xl2tpd run as foreground process while logging via syslog. Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com> - bumped version - removed dependency on `ip` package as routes are setup by netifd if iproute2 is actually required, please depend on `@(PACKAGE_ip||PACKAGE_ip-full)` instead of `ip` Signed-off-by: Daniel Golle <daniel@makrotopia.org>
23 lines
352 B
Bash
23 lines
352 B
Bash
#!/bin/sh /etc/rc.common
|
|
# Copyright (C) 2006-2015 OpenWrt.org
|
|
|
|
START=60
|
|
USE_PROCD=1
|
|
|
|
BIN=xl2tpd
|
|
RUN_D="/var/run/xl2tpd"
|
|
PID_F="/var/run/xl2tpd.pid"
|
|
|
|
start_service() {
|
|
rm -rf "$RUN_D"
|
|
mkdir -p "$RUN_D"
|
|
|
|
procd_open_instance
|
|
procd_set_param command $BIN -D -l -p "$PID_F"
|
|
procd_close_instance
|
|
}
|
|
|
|
stop_service() {
|
|
rm -rf "$RUN_D"
|
|
rm -rf "$PID_F"
|
|
}
|