diff options
author | Mathieu Arnold <mat@FreeBSD.org> | 2017-11-07 15:48:16 +0000 |
---|---|---|
committer | Mathieu Arnold <mat@FreeBSD.org> | 2017-11-07 15:48:16 +0000 |
commit | 8ab9e7cb3e1b6b402d568297cc2a6ed2b1cd97c2 (patch) | |
tree | 76cc5ac0453d261b8101e6d1a033edf1c7f87782 /dns/bind910 | |
parent | fd08254023ec49cb88da271bdeb8d6e9bb5fccae (diff) | |
download | ports-8ab9e7cb3e1b6b402d568297cc2a6ed2b1cd97c2.tar.gz ports-8ab9e7cb3e1b6b402d568297cc2a6ed2b1cd97c2.zip |
Notes
Diffstat (limited to 'dns/bind910')
-rw-r--r-- | dns/bind910/Makefile | 2 | ||||
-rw-r--r-- | dns/bind910/files/named.in | 22 |
2 files changed, 22 insertions, 2 deletions
diff --git a/dns/bind910/Makefile b/dns/bind910/Makefile index aa620e933d3c..466b251cd956 100644 --- a/dns/bind910/Makefile +++ b/dns/bind910/Makefile @@ -3,7 +3,7 @@ PORTNAME= bind PORTVERSION= ${ISCVERSION:S/-P/P/:S/b/.b/:S/a/.a/:S/rc/.rc/} -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= dns net ipv6 MASTER_SITES= ISC/bind9/${ISCVERSION} PKGNAMESUFFIX= 910 diff --git a/dns/bind910/files/named.in b/dns/bind910/files/named.in index 33b76d151028..bf5ee86465f2 100644 --- a/dns/bind910/files/named.in +++ b/dns/bind910/files/named.in @@ -175,7 +175,8 @@ chroot_autoupdate() make_symlinks() { checkyesno named_symlink_enable && - ln -fs "${named_chrootdir}${pidfile}" ${pidfile} + ln -fs "${named_chrootdir}${pidfile}" ${pidfile} && + ln -fs "${named_chrootdir}${sessionkeyfile}" ${sessionkeyfile} } named_poststart() @@ -206,6 +207,15 @@ find_pidfile() fi } +find_sessionkeyfile() +{ + if get_pidfile_from_conf session-keyfile ${named_conf}; then + sessionkeyfile="${_pidfile_from_conf}" + else + sessionkeyfile="/var/run/named/session.key" + fi +} + named_stop() { find_pidfile @@ -273,16 +283,26 @@ rndc() named_prestart() { find_pidfile + find_sessionkeyfile if [ -n "${named_pidfile}" ]; then warn 'named_pidfile: now determined from the conf file' fi + if [ -n "${named_sessionkeyfile}" ]; then + warn 'named_sessionkeyfile: now determined from the conf file' + fi + piddir=`/usr/bin/dirname ${pidfile}` if [ ! -d ${piddir} ]; then install -d -o ${named_uid} -g ${named_uid} ${piddir} fi + sessionkeydir=`/usr/bin/dirname ${sessionkeyfile}` + if [ ! -d ${sessionkeydir} ]; then + install -d -o ${named_uid} -g ${named_uid} ${sessionkeydir} + fi + command_args="-u ${named_uid:=root} -c ${named_conf} ${command_args}" %%NATIVE_PKCS11%% if [ -z "${named_pkcs11_engine}"]; then |