summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2019-07-09 17:55:59 +0200
committerGregor Kleen <gkleen@yggdrasil.li>2019-07-09 17:55:59 +0200
commit2d1266fb05817c433d6ae9d145ed693deffa2572 (patch)
tree59d2f46b08b72fc96e6b120ba9208a8e03f34f0d
parent5deb9aca5eb238d95d662033723e2a4b5cf5cb64 (diff)
downloadnixos-2d1266fb05817c433d6ae9d145ed693deffa2572.tar
nixos-2d1266fb05817c433d6ae9d145ed693deffa2572.tar.gz
nixos-2d1266fb05817c433d6ae9d145ed693deffa2572.tar.bz2
nixos-2d1266fb05817c433d6ae9d145ed693deffa2572.tar.xz
nixos-2d1266fb05817c433d6ae9d145ed693deffa2572.zip
...
-rw-r--r--hel.nix11
1 files changed, 8 insertions, 3 deletions
diff --git a/hel.nix b/hel.nix
index e2718ce9..82ec5109 100644
--- a/hel.nix
+++ b/hel.nix
@@ -144,10 +144,14 @@
144 }; 144 };
145 145
146 systemd.services."unbound" = { 146 systemd.services."unbound" = {
147 path = with pkgs; [ unbound openssl ];
148
149 preStart = '' 147 preStart = ''
150 unbound-control-setup -d /var/lib/unbound 148 if [[ -d /etc/unbound ]]; then
149 ${pkgs.util-linux}/bin/mkdir -p /var/lib/unbound/etc/unbound
150 ${pkgs.util-linux}/bin/mount --bind -n /etc/unbound /var/lib/unbound/etc/unbound
151 fi
152 '';
153 postStop = ''
154 ${pkgs.util-linux}/bin/umount /var/lib/unbound/etc/unbound
151 ''; 155 '';
152 }; 156 };
153 157
@@ -157,6 +161,7 @@
157 extraConfig = '' 161 extraConfig = ''
158 remote-control: 162 remote-control:
159 control-enable: yes 163 control-enable: yes
164
160 ''; 165 '';
161 }; 166 };
162 167