Add hardened systemd-resolved DNS with boot verification and journal recovery, enabled only on specific hosts: - hl-bigbox1, hl-bigbox2 (experienced DNS resilience issues) - hl-minipc1, hl-minipc2, hl-minipc3 (minipc cluster) - hl-fwdesk, hl-fws1 (desktop/workstation nodes) Changes: 1. New module: modules/nixos/common/dns/default.nix - systemd-resolved with LLMNR fallback and DNSSEC tolerance - Hardened journald with persistent storage and auto-recovery - Boot-time DNS verification service with 5 retries - Systemd watchdog for automatic reboot on DNS failure 2. Default to false, enabled explicitly on target hosts only 3. Updated host configs to enable dns resilience module
40 lines
878 B
Nix
40 lines
878 B
Nix
{ skyg-secrets, ... }:
|
|
{
|
|
imports = [
|
|
./hardware-configuration
|
|
./systemd.nix
|
|
./services
|
|
];
|
|
|
|
skyg.user.enable = true;
|
|
skyg.nixos.common.ssh-server.enable = true;
|
|
skyg.nixos.common.diagnix.enable = true;
|
|
skyg.nixos.common.dns.enable = true;
|
|
skyg.server.dns.routing = {
|
|
enable = false;
|
|
openFirewall = true;
|
|
addressesSecretName = "dns-addresses.conf";
|
|
};
|
|
|
|
|
|
skyg.nixos.server.k3s = {
|
|
enable = true;
|
|
envPath = "/opt/k3s/k3s.env";
|
|
};
|
|
skyg.nixos.common.containers.networks.ipvlanLab = {
|
|
enable = true;
|
|
parent = "eno1";
|
|
};
|
|
age.secrets.portainer-agent-minipc3.file = skyg-secrets.portainer-agent-minipc3;
|
|
skyg.nixos.server.portainer = {
|
|
enable = true;
|
|
mode = "agent";
|
|
agent.k3s = {
|
|
enable = true;
|
|
edgeKeySecretName = "portainer-agent-minipc3";
|
|
};
|
|
};
|
|
|
|
networking.firewall.enable = false;
|
|
}
|