#134_limit-dns #135

Merged
silver merged 4 commits from #134_limit-dns into main 2024-10-09 14:16:48 +00:00
Showing only changes of commit 91d76c08f1 - Show all commits

View file

@ -13,11 +13,14 @@
current_date = self.lastModified;
# this gets a list of all domains we have records for
domains = lib.lists.naturalSort (
lib.lists.unique (
lib.lists.forEach records (x: x.domain)
)
);
domains = lib.lists.naturalSort (lib.lists.unique (
lib.lists.forEach records (x: x.domain)
));
# get the ip's of our servers
servers = lib.lists.naturalSort (lib.lists.unique (
lib.lists.forEach (sort_records_server records) (x: x.value)
));
domains_owned = [
# for historic reasons we own this
@ -175,7 +178,9 @@
);
# small function to tidy up the spam of the cache networks, would use teh subnet except all external traffic has the ip of teh router
create_cache_networks = map (x: "193.1.99.${toString x}/32") (lib.lists.range 71 126);
# now limited explicitly to servers that we are administering
# See i24-09-30_050 for more information
create_cache_networks = map (x: "${toString x}/32") servers;
# standard function to create the etc file, pass in the text and domain and it makes it
create_entry_etc_sub = domain: text: {
@ -238,7 +243,7 @@
*/
++ builtins.concatLists (
lib.attrsets.mapAttrsToList (
key: value: value.config.services.skynet."${name}".records
key: value: value.config.services.skynet.dns.records
)
nodes
);