mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
unbound: add UCI for forward stub and auth zone clauses
With growing interest, DNS over TLS can be setup in Unbounds foward-zone: clause. A broader UCI solution is added to support forward-, stub-, and auth- zone clauses in a new 'zone' section. This implentation required reworking scripts, because they did not scale. 'forward_domain' and 'prefetch_root' options are removed, and superceded by 'zone' section. Signed-off-by: Eric Luehrsen <ericluehrsen@gmail.com>
This commit is contained in:
@@ -17,14 +17,14 @@ PROG=/usr/sbin/unbound
|
||||
##############################################################################
|
||||
|
||||
boot() {
|
||||
UNBOUND_BOOT=1
|
||||
UB_BOOT=1
|
||||
start "$@"
|
||||
}
|
||||
|
||||
##############################################################################
|
||||
|
||||
start_service() {
|
||||
if [ -n "$UNBOUND_BOOT" ] ; then
|
||||
if [ -n "$UB_BOOT" ] ; then
|
||||
# Load procd triggers (rc) and use event IFUP to really start
|
||||
return 0
|
||||
fi
|
||||
@@ -35,7 +35,7 @@ start_service() {
|
||||
|
||||
# standard procd clause
|
||||
procd_open_instance "unbound"
|
||||
procd_set_param command $PROG -d -c $UNBOUND_CONFFILE
|
||||
procd_set_param command $PROG -d -c $UB_TOTAL_CONF
|
||||
procd_set_param respawn
|
||||
procd_close_instance
|
||||
}
|
||||
@@ -44,7 +44,7 @@ start_service() {
|
||||
|
||||
stop_service() {
|
||||
# clean up
|
||||
. /usr/lib/unbound/unbound.sh
|
||||
. /usr/lib/unbound/stopping.sh
|
||||
unbound_stop
|
||||
|
||||
# Wait! on restart Unbound may take time writing closure stats to syslog
|
||||
|
||||
Reference in New Issue
Block a user