/etc/init/tftpd-hpa.conf is in tftpd-hpa 5.2+20150808-1ubuntu3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | description "tftp-hpa server"
start on runlevel [2345]
stop on runlevel [!2345]
expect fork
respawn
env DEFAULTS="/etc/default/tftpd-hpa"
env PIDFILE="/var/run/tftpd-hpa.pid"
pre-start script
if [ -f ${DEFAULTS} ]
then
. ${DEFAULTS}
fi
# Ensure --secure and multiple server directories are not used at the
# same time
if [ "$(echo ${TFTP_DIRECTORY} | wc -w)" -ge 2 ] && echo ${TFTP_OPTIONS} | grep -qs secure
then
echo
echo "When --secure is specified, exactly one directory can be specified."
echo "Please correct your /etc/default/tftpd-hpa."
stop
exit 0
fi
# Ensure server directories are existing
for _DIRECTORY in ${TFTP_DIRECTORY}
do
if [ ! -d "${_DIRECTORY}" ]
then
echo "${_DIRECTORY} missing, aborting."
stop
exit 0
fi
done
end script
script
if [ -f ${DEFAULTS} ]
then
. ${DEFAULTS}
fi
exec /usr/sbin/in.tftpd --listen --user ${TFTP_USERNAME} --address ${TFTP_ADDRESS} ${TFTP_OPTIONS} ${TFTP_DIRECTORY}
end script
|