From c87fec1a65d6af52b4ba2b17f1e642addc674547 Mon Sep 17 00:00:00 2001 From: Brendan Golden Date: Sat, 30 Sep 2023 22:06:18 +0100 Subject: [PATCH] feat: will restart dns when the related files are changed --- applications/dns.nix | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/applications/dns.nix b/applications/dns.nix index 3ade43f..f337055 100644 --- a/applications/dns.nix +++ b/applications/dns.nix @@ -415,11 +415,16 @@ in { ++ create_cache_networks; }; - # deletes teh journal files evey start so it no longer stalls out - systemd.services.bind.preStart = '' - rm -vf /etc/skynet/dns/*.jnl - rm -vf /etc/skynet/dns/*.jbk - ''; + systemd.services.bind = { + # deletes teh journal files evey start so it no longer stalls out + preStart = '' + rm -vf /etc/skynet/dns/*.jnl + rm -vf /etc/skynet/dns/*.jbk + ''; + restartTriggers = [ + "${config.environment.etc."skynet/dns/skynet.ie".source}" + ]; + }; # creates a folder in /etc for the dns to use users.users.named = {