summaryrefslogtreecommitdiff
path: root/template
diff options
context:
space:
mode:
authorAndreas Baumann <mail@andreasbaumann.cc>2016-01-23 16:51:14 +0100
committerAndreas Baumann <mail@andreasbaumann.cc>2016-01-23 16:51:14 +0100
commit6ae34b299bb711f63da760e30ba800b05d408555 (patch)
treeed47b1701dfe82e200ca72361d0efdeb3e09c38e /template
parent3979a017b245c98d7a49eb354caf78c58bed30bb (diff)
downloadOpenBSD-firewall-6ae34b299bb711f63da760e30ba800b05d408555.tar.gz
OpenBSD-firewall-6ae34b299bb711f63da760e30ba800b05d408555.tar.bz2
having a restart_dns script (for now with unbound), added forwarders
Diffstat (limited to 'template')
-rwxr-xr-xtemplate/usr/sbin/restart_dns15
1 files changed, 15 insertions, 0 deletions
diff --git a/template/usr/sbin/restart_dns b/template/usr/sbin/restart_dns
new file mode 100755
index 0000000..bbe8cdb
--- /dev/null
+++ b/template/usr/sbin/restart_dns
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+echo "unbound: stopping ..."
+pkill unbound
+sleep 3
+
+echo "unbound: redeploy from persistent /etc/unbound to /var/unboud ..."
+rm -rf /tmp/var/unbound
+cp -R /etc/unbound /tmp/var/unbound
+chown -R _unbound:_unbound /tmp/var/unbound/db
+
+echo "unbound: restarting ..."
+/usr/sbin/unbound
+
+echo "unbound: running."