diff options
Diffstat (limited to 'comms/smstools3/files/smsd.in')
-rw-r--r-- | comms/smstools3/files/smsd.in | 31 |
1 files changed, 14 insertions, 17 deletions
diff --git a/comms/smstools3/files/smsd.in b/comms/smstools3/files/smsd.in index 2dec3b9ad417..b1d7d1fcda02 100644 --- a/comms/smstools3/files/smsd.in +++ b/comms/smstools3/files/smsd.in @@ -10,25 +10,22 @@ # # smsd_enable="YES" # -smsd_enable=${smsd_enable-"NO"} - -. %%RC_SUBR%% +. "%%RC_SUBR%%" name="smsd" + +load_rc_config ${name} +: ${smsd_enable="NO"} +: ${smsd_pidfile="%%PIDDIR%%/smsd.pid"} +: ${smsd_infofile="%%PIDDIR%%/smsd.working"} +: ${smsd_logfile="%%LOGDIR%%/smsd.log"} +: ${smsd_config="%%PREFIX%%/etc/smsd.conf"} +: ${smsd_user="uucp"} +: ${smsd_group="dialer"} + rcvar=`set_rcvar` -load_rc_config $name -pidfile="/var/run/smsd.pid" +pidfile=${smsd_pidfile} command="%%PREFIX%%/bin/smsd" -command_args='&' - -# Unfortunally we need to this because as the program won't -# exit cleanly and the terminal will be stuck forever in waitpid. -case "$1" in - stop) - pkill smsd - ;; - *) - run_rc_command "$1" - ;; -esac +command_args="-c${smsd_config} -p${smsd_pidfile} -i${smsd_infofile} -l${smsd_logfile} -u${smsd_user} -g${smsd_group}" +run_rc_command "$1" |