From 4eafde1b88e628cc78b147cab127c0fdf58a458c Mon Sep 17 00:00:00 2001 From: xinyangli Date: Tue, 4 Mar 2025 18:32:55 +0800 Subject: [PATCH] calcite: test comin --- flake.lock | 8 ++++---- flake.nix | 19 ++++++++----------- garnix.yaml | 11 +---------- home/xin/calcite.nix | 1 + machines/calcite/configuration.nix | 2 +- machines/calcite/network.nix | 30 ++++++++++++++++++++++++++---- 6 files changed, 41 insertions(+), 30 deletions(-) diff --git a/flake.lock b/flake.lock index 12a9f4f..c207939 100644 --- a/flake.lock +++ b/flake.lock @@ -401,11 +401,11 @@ "nixvim": "nixvim" }, "locked": { - "lastModified": 1735219902, - "narHash": "sha256-s1aI4l9e0OX861wHsvAPqz/s8B9ZTltAMJzPRXt5Kqo=", + "lastModified": 1741086060, + "narHash": "sha256-35fw6MoEXEutctwNS0z7VQ0AX8thHhU2KT0UxD/s3P4=", "ref": "refs/heads/master", - "rev": "4439691030d1a28f4ad49c542104e3f880f7c183", - "revCount": 25, + "rev": "9240bb4db98fe13b3fdaa0e15a06949959df568a", + "revCount": 26, "type": "git", "url": "https://git.xiny.li/xin/nixvim" }, diff --git a/flake.nix b/flake.nix index abd9da6..f81f61a 100644 --- a/flake.nix +++ b/flake.nix @@ -123,6 +123,9 @@ comin.nixosModules.comin ]; nodeNixosModules = { + weilite = [ + ./machines/weilite + ]; calcite = [ nixos-hardware.nixosModules.asus-zephyrus-ga401 catppuccin.nixosModules.catppuccin @@ -269,17 +272,6 @@ ] ++ sharedColmenaModules; }; - weilite = - { ... }: - { - imports = [ machines/weilite ] ++ sharedColmenaModules; - deployment = { - targetHost = "weilite.coho-tet.ts.net"; - targetPort = 22; - buildOnTarget = false; - }; - nixpkgs.system = "x86_64-linux"; - }; thorite = { ... }: { @@ -309,6 +301,11 @@ calcite = mkNixos { hostname = "calcite"; }; + + weilite = mkNixos { + hostname = "weilite"; + }; + baryte = mkNixos { hostname = "baryte"; }; diff --git a/garnix.yaml b/garnix.yaml index 630fac6..c9f5129 100644 --- a/garnix.yaml +++ b/garnix.yaml @@ -7,13 +7,4 @@ builds: - homeConfigurations.aarch64-linux.* - darwinConfigurations.* - nixosConfigurations.* - branch: deploy - - include: - - '*.x86_64-linux.*' - - defaultPackage.x86_64-linux - - devShell.x86_64-linux - - homeConfigurations.x86_64-linux.* - - homeConfigurations.aarch64-linux.* - - darwinConfigurations.* - - nixosConfigurations.* - branch: next + branch: testing-calcite diff --git a/home/xin/calcite.nix b/home/xin/calcite.nix index 40b93c9..8d83d35 100644 --- a/home/xin/calcite.nix +++ b/home/xin/calcite.nix @@ -122,6 +122,7 @@ in enable = true; options = { recolor = false; + selection-clipboard = "clipboard"; }; }; diff --git a/machines/calcite/configuration.nix b/machines/calcite/configuration.nix index e5a74ea..c9afcd5 100644 --- a/machines/calcite/configuration.nix +++ b/machines/calcite/configuration.nix @@ -188,8 +188,8 @@ in services.printing.enable = true; services.printing.drivers = [ pkgs.hplip + pkgs.gutenprint pkgs.gutenprintBin - pkgs.canon-cups-ufr2 ]; hardware.sane = { enable = true; diff --git a/machines/calcite/network.nix b/machines/calcite/network.nix index 27e77ee..0626cc9 100644 --- a/machines/calcite/network.nix +++ b/machines/calcite/network.nix @@ -12,19 +12,41 @@ networking = { networkmanager = { enable = true; - dns = "systemd-resolved"; + dns = "default"; + settings = { + main = { + rc-manager = "resolvconf"; + }; + }; }; }; - services.resolved = { + networking.resolvconf = { enable = true; + dnsExtensionMechanism = false; + useLocalResolver = false; + }; + + services.kresd = { + enable = true; + listenPlain = [ ]; extraConfig = '' - Cache=no + log_level("notice") + net.listen('127.0.0.1', 53) + modules = { 'hints > iterate', 'stats', 'predict' } + cache.size = 100 * MB + trust_anchors.remove(".") + policy.add(policy.all(policy.TLS_FORWARD( { + { "8.8.8.8", hostname="dns.google" } }))) ''; + # policy.add(policy.suffix(policy.FORWARD({ "100.100.100.100" }), policy.todnames({ 'coho-tet.ts.net' }))) }; # Enable Tailscale - services.tailscale.enable = true; + services.tailscale = { + enable = true; + extraUpFlags = [ "--accept-dns=false" ]; + }; # services.tailscale.useRoutingFeatures = "both"; services.dae.enable = true;