This commit is contained in:
4DBug
2026-03-05 11:06:06 -06:00
parent 83c72a1742
commit 20bd5609e4
19 changed files with 145 additions and 82 deletions

View File

@@ -25,6 +25,9 @@
};
folders = {
"Archives" = mkFolder "/home/bug/Archives";
"Software" = mkFolder "/home/bug/Software";
"Scripts" = mkFolder "/home/bug/Scripts";
"Documents" = mkFolder "/home/bug/Documents";
"Downloads" = mkFolder "/home/bug/Downloads";
"Pictures" = mkFolder "/home/bug/Pictures";

View File

@@ -1 +1,41 @@
{}
{
den.aspects.crab-hole = {
nixos = { ... }: {
services.crab-hole = {
enable = true;
settings = {
blocklist = {
include_subdomains = true;
lists = [
"https://raw.githubusercontent.com/StevenBlack/hosts/master/alternates/fakenews-gambling-porn/hosts"
"https://s3.amazonaws.com/lists.disconnect.me/simple_tracking.txt"
];
};
downstream = [
{ protocol = "udp"; listen = "127.0.0.1"; port = 53; }
{ protocol = "udp"; listen = "::1"; port = 53; }
];
upstream = {
name_servers = [
{
socket_addr = "1.1.1.1:853";
protocol = "tls";
tls_dns_name = "1dot1dot1dot1.cloudflare-dns.com";
trust_nx_responses = false;
}
{
socket_addr = "[2606:4700:4700::1111]:853";
protocol = "tls";
tls_dns_name = "1dot1dot1dot1.cloudflare-dns.com";
trust_nx_responses = false;
}
];
};
};
};
};
};
}

View File

@@ -1,10 +1,15 @@
{
den.aspects.dns = {
nixos = {
nixos = { config, lib, ... }: {
networking = {
networkmanager.enable = true;
networkmanager = {
enable = true;
dns = lib.mkIf config.services.crab-hole.enable "none";
};
nameservers = [ "1.1.1.1" "1.0.0.1" ];
nameservers = if config.services.crab-hole.enable
then [ "127.0.0.1" "::1" ]
else [ "1.1.1.1" "1.0.0.1" ];
};
};
};