about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAzat Bahawi <azat@bahawi.net>2023-12-10 13:31:47 +0300
committerAzat Bahawi <azat@bahawi.net>2023-12-10 13:31:47 +0300
commit186e475665b9c95e5843c94749e9948540def8bb (patch)
treefc392d76953f2d3095cfcde438f8d0dccefcb300
parent2023-12-10 (diff)
2023-12-10
-rw-r--r--modules/nixos/unbound.nix22
1 files changed, 11 insertions, 11 deletions
diff --git a/modules/nixos/unbound.nix b/modules/nixos/unbound.nix
index 18e6867..8dce3f5 100644
--- a/modules/nixos/unbound.nix
+++ b/modules/nixos/unbound.nix
@@ -69,21 +69,21 @@ in {
 
               local-zone =
                 concatLists
-                (mapAttrsToList (h: _: [''"${h}.${cfg.domain}" redirect''])
+                (mapAttrsToList (h: _: ["\"${h}.${cfg.domain}\" redirect"])
                   my.configurations);
               local-data = concatLists (mapAttrsToList (hostname: let
                 domain = "${hostname}.${cfg.domain}";
               in
                 attr: (optionals (hasAttr "wireguard" attr) (with attr.wireguard;
                   [
-                    ''"${domain} 604800 IN A ${ipv4.address}"''
-                    ''"${domain} 604800 IN AAAA ${ipv6.address}"''
-                    ''"${domain}. A ${ipv4.address}"''
-                    ''"${domain}. AAAA ${ipv6.address}"''
+                    "\"${domain} 604800 IN A ${ipv4.address}\""
+                    "\"${domain} 604800 IN AAAA ${ipv6.address}\""
+                    "\"${domain}. A ${ipv4.address}\""
+                    "\"${domain}. AAAA ${ipv6.address}\""
                   ]
                   ++ concatMap (domain: [
-                    ''"${domain}. A ${ipv4.address}"''
-                    ''"${domain}. AAAA ${ipv6.address}"''
+                    "\"${domain}. A ${ipv4.address}\""
+                    "\"${domain}. AAAA ${ipv6.address}\""
                   ])
                   attr.domains)))
               my.configurations);
@@ -92,12 +92,12 @@ in {
               in
                 attr: (optionals (hasAttr "wireguard" attr) (with attr.wireguard;
                   [
-                    ''"${ipv4.address} ${domain}"''
-                    ''"${ipv6.address} ${domain}"''
+                    "\"${ipv4.address} ${domain}\""
+                    "\"${ipv6.address} ${domain}\""
                   ]
                   ++ concatMap (domain: [
-                    ''"${ipv4.address} ${domain}"''
-                    ''"${ipv6.address} ${domain}"''
+                    "\"${ipv4.address} ${domain}\""
+                    "\"${ipv6.address} ${domain}\""
                   ])
                   attr.domains)))
               my.configurations);

Consider giving Nix/NixOS a try! <3