0696600c41
The reasons for this are forward looking to pkgbase: * /sbin/init is a special binary; try not to replace it with every package update because an rc script was touched. (a follow-up commit will make init its own package) * having rc in its own place will allow more easy replacement of the rc framework with alternatives, such as openrc. Discussed with: brd (during BSDCam), kmoore Requested by: cem, bz PR: 231522 Approved by: re (gjb)
35 lines
585 B
Bash
Executable File
35 lines
585 B
Bash
Executable File
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
# PROVIDE: pppoed
|
|
# REQUIRE: NETWORKING
|
|
# BEFORE: DAEMON
|
|
# KEYWORD: nojail
|
|
|
|
. /etc/rc.subr
|
|
|
|
name="pppoed"
|
|
desc="Handle incoming PPP over Ethernet connections"
|
|
rcvar="pppoed_enable"
|
|
start_cmd="pppoed_start"
|
|
# XXX stop_cmd will not be straightforward
|
|
stop_cmd=":"
|
|
|
|
pppoed_start()
|
|
{
|
|
local _opts
|
|
|
|
if [ -n "${pppoed_provider}" ]; then
|
|
pppoed_flags="${pppoed_flags} -p ${pppoed_provider}"
|
|
fi
|
|
echo 'Starting pppoed'
|
|
_opts=$-; set -f
|
|
/usr/libexec/pppoed ${pppoed_flags} ${pppoed_interface}
|
|
set +f; set -${_opts}
|
|
}
|
|
|
|
load_rc_config $name
|
|
run_rc_command "$1"
|