mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 01:39:16 -04:00
dns/knot2: update to 2.7.5
While here, patch init script to support automatically determining config type PR: 234751 Submitted by: Leo Vandewoestijne <freebsd@dns.company> (maintainer)
This commit is contained in:
parent
ba2a5298d4
commit
25e87da2c1
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=489774
3 changed files with 27 additions and 12 deletions
|
@ -2,8 +2,7 @@
|
||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
|
|
||||||
PORTNAME= knot
|
PORTNAME= knot
|
||||||
DISTVERSION= 2.7.4
|
DISTVERSION= 2.7.5
|
||||||
PORTREVISION= 2
|
|
||||||
CATEGORIES= dns ipv6
|
CATEGORIES= dns ipv6
|
||||||
MASTER_SITES= https://secure.nic.cz/files/knot-dns/ \
|
MASTER_SITES= https://secure.nic.cz/files/knot-dns/ \
|
||||||
https://dns.company/downloads/knot-dns/
|
https://dns.company/downloads/knot-dns/
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
TIMESTAMP = 1542114322
|
TIMESTAMP = 1546941720
|
||||||
SHA256 (knot-2.7.4.tar.xz) = acebe2fbcd8f67b0cb8969376114855316fe831df08321b795147502a5e9fd74
|
SHA256 (knot-2.7.5.tar.xz) = 7d70d6d8f708285517d1d7c4ff2e5ddfd119cd2962c7a8d3f50a4c695209a086
|
||||||
SIZE (knot-2.7.4.tar.xz) = 1148652
|
SIZE (knot-2.7.5.tar.xz) = 1150904
|
||||||
|
|
|
@ -33,6 +33,7 @@
|
||||||
#
|
#
|
||||||
# # optional:
|
# # optional:
|
||||||
# NAME_config="%%PREFIX%%/etc/knot/NAME.conf" # (-c)onfig file
|
# NAME_config="%%PREFIX%%/etc/knot/NAME.conf" # (-c)onfig file
|
||||||
|
# NAME_config="db:/var/db/knot/confdb" # (-C)onfig database
|
||||||
# NAME_diruser="%%USERS%%" # /var/db/NAME and /var/run/NAME are created if they
|
# NAME_diruser="%%USERS%%" # /var/db/NAME and /var/run/NAME are created if they
|
||||||
# NAME_dirgroup="%%GROUPS%%" # don't exist. These don't control the user/group knot
|
# NAME_dirgroup="%%GROUPS%%" # don't exist. These don't control the user/group knot
|
||||||
# # runs as, the config file has a setting for that.
|
# # runs as, the config file has a setting for that.
|
||||||
|
@ -72,11 +73,26 @@ diruser="$(eval echo \${${name}_diruser})"
|
||||||
dirgroup="$(eval echo \${${name}_dirgroup})"
|
dirgroup="$(eval echo \${${name}_dirgroup})"
|
||||||
|
|
||||||
command=%%PREFIX%%/sbin/knotd
|
command=%%PREFIX%%/sbin/knotd
|
||||||
command_args="-c ${configfile} -d"
|
case "$configfile" in
|
||||||
control=%%PREFIX%%/sbin/knotc
|
db:*)
|
||||||
pidfile=/var/run/${name}/knot.pid
|
config_args="-C ${configfile#db:}"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
config_args="-c ${configfile}"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
command_args="${config_args} -d"
|
||||||
|
control="%%PREFIX%%/sbin/knotc"
|
||||||
|
pidfile="/var/run/${name}/knot.pid"
|
||||||
|
|
||||||
|
case "$configfile" in
|
||||||
|
db:*)
|
||||||
|
required_files=${configfile#db:}/data.mdb
|
||||||
|
;;
|
||||||
|
*)
|
||||||
required_files=${configfile}
|
required_files=${configfile}
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
extra_commands=reload
|
extra_commands=reload
|
||||||
reload_cmd="knot_reload"
|
reload_cmd="knot_reload"
|
||||||
|
@ -90,13 +106,13 @@ knot_prestart()
|
||||||
if [ ! -d /var/db/${name} ]; then
|
if [ ! -d /var/db/${name} ]; then
|
||||||
install -d -o ${diruser} -g ${dirgroup} /var/db/${name}
|
install -d -o ${diruser} -g ${dirgroup} /var/db/${name}
|
||||||
fi
|
fi
|
||||||
${control} -c ${configfile} conf-check
|
${control} ${config_args} conf-check
|
||||||
}
|
}
|
||||||
|
|
||||||
knot_reload()
|
knot_reload()
|
||||||
{
|
{
|
||||||
echo "Reloading ${name}."
|
echo "Reloading ${name}."
|
||||||
${control} -c ${configfile} reload
|
${control} ${config_args} reload
|
||||||
}
|
}
|
||||||
|
|
||||||
run_rc_command "$1"
|
run_rc_command "$1"
|
||||||
|
|
Loading…
Add table
Reference in a new issue