From a677ee8beb2eee184176f33361fe0fa6355314d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dag-Erling=20Sm=C3=B8rgrav?= Date: Tue, 1 Dec 2015 13:20:21 +0000 Subject: [PATCH] Load our configuration before setting defaults, so local_unbound_workdir actually has an effect. PR: 204931 Submitted by: Eugene Grosbein MFC after: 1 week --- etc/rc.d/local_unbound | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/etc/rc.d/local_unbound b/etc/rc.d/local_unbound index 4bb1a0c4dcd9..0cd1ff3e6232 100755 --- a/etc/rc.d/local_unbound +++ b/etc/rc.d/local_unbound @@ -24,6 +24,8 @@ configtest_cmd="local_unbound_configtest" setup_cmd="local_unbound_setup" pidfile="/var/run/${name}.pid" +load_rc_config $name + : ${local_unbound_workdir:=/var/unbound} : ${local_unbound_config:=${local_unbound_workdir}/unbound.conf} : ${local_unbound_flags:="-c ${local_unbound_config}"} @@ -32,8 +34,6 @@ pidfile="/var/run/${name}.pid" : ${local_unbound_anchor:=${local_unbound_workdir}/root.key} : ${local_unbound_forwarders:=} -load_rc_config $name - do_as_unbound() { echo "$@" | su -m unbound