[BACK]Return to unbound CVS log [TXT][DIR] Up to [local] / src / etc / rc.d

File: [local] / src / etc / rc.d / unbound (download)

Revision 1.7, Sat May 21 10:10:45 2022 UTC (2 years ago) by ajacoutot
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, HEAD
Changes since 1.6: +2 -2 lines

No need for true(1).

#!/bin/ksh
#
# $OpenBSD: unbound,v 1.7 2022/05/21 10:10:45 ajacoutot Exp $

daemon="/usr/sbin/unbound"
daemon_flags="-c /var/unbound/etc/unbound.conf"

. /etc/rc.d/rc.subr

rc_pre() {
	if grep '^[[:space:]]*auto-trust-anchor-file:' \
            /var/unbound/etc/unbound.conf > /dev/null 2>&1; then
		/usr/sbin/unbound-anchor -v
	fi
	/usr/sbin/unbound-checkconf || return 1
}

rc_cmd $1