diff options
author | Timo Teräs <timo.teras@iki.fi> | 2013-07-12 08:50:26 +0300 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2013-07-12 09:28:01 +0300 |
commit | 3c24eab6e249a1b8f20770fa4f73557eb4eabde2 (patch) | |
tree | ad00a25ec2e75ba793bb45c3cae9e1ef1cfcceac /testing/gdnsd/gdnsd.initd | |
parent | bbc06ec1abefc220a621547bc31befeb5d6046b5 (diff) | |
download | aports-3c24eab6e249a1b8f20770fa4f73557eb4eabde2.tar.bz2 aports-3c24eab6e249a1b8f20770fa4f73557eb4eabde2.tar.xz |
testing/gdnsd: experimental version 1.9.0
* update to upstream 1.9.0
* updated to use userspace-rcu
* cherry-pick cname reply fix
* refreshed djbdns support patch (from upstream dev branch)
* updated init.d script
Diffstat (limited to 'testing/gdnsd/gdnsd.initd')
-rwxr-xr-x | testing/gdnsd/gdnsd.initd | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/testing/gdnsd/gdnsd.initd b/testing/gdnsd/gdnsd.initd new file mode 100755 index 0000000000..9820052bee --- /dev/null +++ b/testing/gdnsd/gdnsd.initd @@ -0,0 +1,53 @@ +#!/sbin/runscript + +name="gdnsd daemon" +extra_commands="configtest" +extra_started_commands="reload fastrestart" +description="Geographic Authoritative DNS server" +description_configtest="Run syntax tests for configuration files only." +description_reload="Signal running gdnsd to reload configuration files" +description_fastrestart="Optimized restart sequence (minimizes down time)" + +if [ -z "${GDNSD_CONFFILE}" ]; then + if [ "${SVCNAME}" = "gdnsd" ]; then + GDNSD_ROOT=system + else + GDNSD_ROOT=/var/gdnsd/${SVCNAME} + fi +fi + +depend() { + need net + use logger + after firewall + provide auth-dns +} + +act() { + ebegin "$1 ${SVCNAME}" + /usr/sbin/gdnsd -d ${GDNSD_ROOT} $2 + eend $? +} + +configtest() { + act "Checking configuration" checkconf +} + +start() { + act "Starting" start +} + +stop () { + if [ "${RC_CMD}" = "restart" ]; then + configtest || return 1 + fi + act "Stopping" stop +} + +fastrestart() { + act "Restarting" restart +} + +reload() { + act "Reloading" reload +} |