summaryrefslogtreecommitdiff
path: root/ftp/tftp-hpa/files/tftpd.in
blob: ad5fc47f1ec8c20239eec06362bc3b01411dd54f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/sh

# $FreeBSD$
#
# PROVIDE: tftpd
# REQUIRE: NETWORKING
# KEYWORD: shutdown
#
# Add the following line to /etc/rc.conf to enable tftpd:
#
# tftpd_enable="YES"
#

. /etc/rc.subr

name="tftpd"
rcvar=`set_rcvar`
pidfile=${tftpd_pidfile:-"/var/run/tftpd.pid"}
command="%%PREFIX%%/libexec/in.tftpd"
command_args="-P $pidfile -l"

load_rc_config $name
: ${tftpd_enable:="NO"}
: ${tftpd_flags:="-s %%PREFIX%%/tftp"}

run_rc_command "$1"