0b68dca8c905ec94bd62c23c57d9e81872085dfe
[lhc/ateliers.git] / etc / sv / unbound / local.sh
1 sudo apt-get install unbound
2 "$tool"/local/insserv-remove unbound
3
4 sudo install -m 644 -o root -g root /dev/stdin /etc/resolv.conf <<-EOF
5 search ${vm_host#*.}
6 nameserver 127.0.0.1
7 #nameserver ${vm_host_nameserver}
8 EOF
9 sudo install -m 440 -o unbound -g unbound \
10 "$tool"/etc/unbound/named.cache \
11 /etc/unbound/named.cache
12
13 m4 \
14 --define=OUTGOING_INTERFACE=$vm_ipv4 \
15 <"$tool"/etc/unbound/unbound.conf |
16 sudo install -m 440 -o unbound -g unbound /dev/stdin \
17 /etc/unbound/unbound.conf