Move libexpat, unbound into core and introduce hnsd
[librecmc/librecmc.git] / package / network / services / unbound / files / unbound.ntpd
1 #!/bin/sh
2 ##############################################################################
3 #
4 # Copyright (C) 2016 Eric Luehrsen
5 #
6 ##############################################################################
7 #
8 # "Restart" Unbound on hotplug NTP ready:
9 # - Only do this the first time when no file exists
10 # - Some of Unbound conf options to not reload run time
11 # - Change the enable flag for DNSSEC date-time checking
12 #
13 ##############################################################################
14
15 # Common file location definitions
16 . /usr/lib/unbound/defaults.sh
17
18 ##############################################################################
19
20 if [ ! -f "$UB_TIME_FILE" -a "$ACTION" = stratum ] ; then
21   date -Is > $UB_TIME_FILE
22   /etc/init.d/unbound enabled && /etc/init.d/unbound restart
23   # Yes, hard RESTART. We need to be absolutely sure to enable DNSSEC.
24 fi
25
26 ##############################################################################
27