aboutsummaryrefslogtreecommitdiff
path: root/dns/dnsdist
diff options
context:
space:
mode:
authorDave Cottlehuber <dch@FreeBSD.org>2021-03-03 22:42:20 +0000
committerDave Cottlehuber <dch@FreeBSD.org>2021-03-03 22:42:20 +0000
commit81d129b86c8c42617ff5492052c2e7e545832344 (patch)
tree37055955474a7bceb65b34d5515f03a77a1512c6 /dns/dnsdist
parent902114193f5f83fa22238f53cdc47926e824664d (diff)
downloadports-81d129b86c8c42617ff5492052c2e7e545832344.tar.gz
ports-81d129b86c8c42617ff5492052c2e7e545832344.zip
dns/dnsdist: ensure pidfile exists & has appropriate permissions
PR: 253887 Approved by: Ralf van der Enden <tremere@cainites.net> (maintainer) Sponsored by: SkunkWerks, GmbH
Notes
Notes: svn path=/head/; revision=567267
Diffstat (limited to 'dns/dnsdist')
-rw-r--r--dns/dnsdist/Makefile2
-rw-r--r--dns/dnsdist/files/dnsdist.in9
2 files changed, 10 insertions, 1 deletions
diff --git a/dns/dnsdist/Makefile b/dns/dnsdist/Makefile
index 687f4c5c12ea..f47bf6f7ae9f 100644
--- a/dns/dnsdist/Makefile
+++ b/dns/dnsdist/Makefile
@@ -3,7 +3,7 @@
PORTNAME= dnsdist
DISTVERSION= 1.5.1
-PORTREVISION= 3
+PORTREVISION= 4
CATEGORIES= dns net
MASTER_SITES= https://downloads.powerdns.com/releases/
diff --git a/dns/dnsdist/files/dnsdist.in b/dns/dnsdist/files/dnsdist.in
index 725cefc15f5e..04e92b2a5697 100644
--- a/dns/dnsdist/files/dnsdist.in
+++ b/dns/dnsdist/files/dnsdist.in
@@ -95,4 +95,13 @@ else
fi
fi
+start_precmd=dnsdist_startprecmd
+
+dnsdist_startprecmd()
+{
+ if [ ! -e ${pidfile} ]; then
+ install -o ${dnsdist_priv_user} -g ${dnsdist_priv_group} /dev/null ${pidfile};
+ fi
+}
+
run_rc_command "$1"