Some SlackBuild scripts for Slackware.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
slackbuilds/n/ddclient/rc.ddclient

27 lines
402 B

#!/bin/bash
[ -f /etc/ddclient/ddclient.conf ] || exit 0
case "$1" in
start)
[ -d /var/cache/ddclient ] || mkdir -p /var/cache/ddclient
ddclient -pid /var/run/ddclient.pid
;;
stop)
[ -f /var/run/ddclient.pid ] && kill $(< /var/run/ddclient.pid)
;;
restart)
$0 stop
sleep 2
$0 start
;;
*)
echo "Usage: $0 {start|stop|restart}"
exit 1
;;
esac
exit 0