3 # Netatalk :NETATALK_VERSION: startup script for systemd.
5 # The method of using this script is not suitable.
6 # This script will be deleted in the future.
9 ATALK_CONF_DIR=:ETCDIR:
13 ATALK_NAME=`echo ${HOSTNAME}|cut -d. -f1`
14 ATALK_UNIX_CHARSET='LOCALE'
15 ATALK_MAC_CHARSET='MAC_ROMAN'
20 AFPD_UAMLIST="-U uams_dhx.so,uams_dhx2.so"
22 CNID_CONFIG="-l log_note"
31 # read in netatalk configuration
32 if [ -f ${ATALK_CONF_DIR}/netatalk.conf ]; then
33 . ${ATALK_CONF_DIR}/netatalk.conf
37 if [ x"${ATALKD_RUN}" != x"no" -a -x ${ATALK_SBIN}/atalkd ]; then
40 if [ -x ${ATALK_BIN}/nbprgstr ]; then
41 ${ATALK_BIN}/nbprgstr -p 4 ${ATALK_NAME}:Workstation${ATALK_ZONE}
42 ${ATALK_BIN}/nbprgstr -p 4 ${ATALK_NAME}:netatalk${ATALK_ZONE}
45 if [ x"${PAPD_RUN}" = x"yes" -a -x ${ATALK_SBIN}/papd ]; then
49 # check for timelord in bin directory
50 if [ x"${TIMELORD_RUN}" = x"yes" -a -x ${ATALK_BIN}/timelord ]; then
54 # check for timelord in sbin directory
55 if [ x"${TIMELORD_RUN}" = x"yes" -a -x ${ATALK_SBIN}/timelord ]; then
56 ${ATALK_SBIN}/timelord
59 # check for a2boot in bin directory
60 if [ x"${A2BOOT_RUN}" = x"yes" -a -x ${ATALK_BIN}/a2boot ]; then
64 # check for a2boot in sbin directory
65 if [ x"${A2BOOT_RUN}" = x"yes" -a -x ${ATALK_SBIN}/a2boot ]; then
70 if [ x"${CNID_METAD_RUN}" = x"yes" -a -x ${ATALK_SBIN}/cnid_metad ]; then
71 ${ATALK_SBIN}/cnid_metad $CNID_CONFIG
74 if [ x"${AFPD_RUN}" = x"yes" -a -x ${ATALK_SBIN}/afpd ]; then
75 ${ATALK_SBIN}/afpd ${AFPD_UAMLIST} -g ${AFPD_GUEST} \
76 -c ${AFPD_MAX_CLIENTS} -n ${ATALK_NAME}${ATALK_ZONE}
80 if [ x"${ATALK_BGROUND}" = x"yes" -a x"${ATALKD_RUN}" != x"no" ]; then
81 netatalk_startup >& /dev/null &