From cc834fd85d14d89d54109c53cd0725758d60a0af Mon Sep 17 00:00:00 2001 From: Nathan Date: Sun, 4 Jan 2026 16:33:14 -0600 Subject: [PATCH] help --- .sops.yaml | 2 +- machines/laptop/.sops.yaml | 28 +------------- system/default.nix | 37 ++----------------- system/profiles/laptop/default.nix | 6 +-- .../home-manager/programs/git/default.nix | 4 +- 5 files changed, 10 insertions(+), 67 deletions(-) diff --git a/.sops.yaml b/.sops.yaml index 0a2ab72..1a52266 100644 --- a/.sops.yaml +++ b/.sops.yaml @@ -25,7 +25,7 @@ creation_rules: - *laptop - *homebox - *android - - path_regex: system-config/secrets.yaml$ + - path_regex: system/secrets.yaml$ key_groups: - age: - *laptop diff --git a/machines/laptop/.sops.yaml b/machines/laptop/.sops.yaml index 0a2ab72..19a8b0a 100644 --- a/machines/laptop/.sops.yaml +++ b/machines/laptop/.sops.yaml @@ -1,33 +1,7 @@ keys: - - &homebox age1640eg0pnmkruc89m5xguz0m8fek44fl4tzez6qwuzlz6kmapqewsp8esxd - &laptop age1yqgyp2uxz4lzrc9f9ka0mfjl5fr6ahf8nf24nlmran2wulg6fpvq9hyp9q - - &android age12pnf36uqesjmy3e0lythfnpwam3zg5mv8m936fc4jphy4ces2fdqwn0s74 creation_rules: - - path_regex: homebox/secrets.yaml$ - key_groups: - - age: - - *homebox - - path_regex: laptop/secrets.yaml$ + - path_regex: ^secrets.yaml$ key_groups: - age: - *laptop - - path_regex: pi4/secrets.yaml$ - key_groups: - - age: - - *laptop - - path_regex: live/secrets.yaml$ - key_groups: - - age: - - *laptop - - path_regex: nathan/secrets.yaml$ - key_groups: - - age: - - *laptop - - *homebox - - *android - - path_regex: system-config/secrets.yaml$ - key_groups: - - age: - - *laptop - - *homebox - - *android diff --git a/system/default.nix b/system/default.nix index d780277..73269d9 100644 --- a/system/default.nix +++ b/system/default.nix @@ -1,4 +1,4 @@ -{ config, lib, pkgs, inputs, modulesPath, ... }: { +{ config, lib, nixpkgs, ... }: { imports = [ ./services @@ -28,41 +28,10 @@ config = { - sops.secrets = (if config.sysconfig.remoteBuildHost then ( - builtins.listToAttrs - (builtins.map - (y: { - name = "remoteBuildClientKeys/${y}"; - value = { - format = "yaml"; - sopsFile = ./secrets.yaml; - }; - }) - (builtins.partition - (z: let - cfg = if - ((builtins.readDir ./configuration).${z} == "directory") - then (import ./configuration/${z} { - config = {}; - inherit lib pkgs inputs modulesPath; - }).config - else null; - test = if cfg == null then false - else if !(cfg ? sysconfig) then false - else if !(cfg.sysconfig ? remoteBuildClient) then false - else cfg.sysconfig.remoteBuildClient; - in test) - (builtins.attrNames (builtins.readDir ./configuration)) - ).right - ) - ) else {}) // { - "remoteBuildKey" = lib.mkIf config.sysconfig.remoteBuildClient {}; - }; - networking.hostName = lib.mkDefault config.sysconfig.host; nix = { - nixPath = [ "nixpkgs=${inputs.nixpkgs}" ]; + nixPath = [ "nixpkgs=${nixpkgs}" ]; channel.enable = false; settings = { experimental-features = [ "nix-command" "flakes" ]; @@ -73,7 +42,7 @@ distributedBuilds = config.sysconfig.remoteBuildClient; buildMachines = lib.mkIf config.sysconfig.remoteBuildClient [ { - hostName = "blunkall.us"; + hostName = "esotericbytes.com"; sshUser = "remote-builder"; sshKey = config.sops.secrets."remoteBuildKey".path; supportedFeatures = [ diff --git a/system/profiles/laptop/default.nix b/system/profiles/laptop/default.nix index 7a3eb39..4eb2f23 100644 --- a/system/profiles/laptop/default.nix +++ b/system/profiles/laptop/default.nix @@ -1,11 +1,11 @@ -{ config, pkgs, lib, inputs, ... }: +{ config, pkgs, lib, home-manager, sops-nix, ... }: { imports = [ - inputs.home-manager.nixosModules.default + home-manager.nixosModules.default - inputs.sops-nix.nixosModules.sops + sops-nix.nixosModules.sops ]; config = { diff --git a/system/users/nathan/home-manager/programs/git/default.nix b/system/users/nathan/home-manager/programs/git/default.nix index 084481e..a263fd1 100644 --- a/system/users/nathan/home-manager/programs/git/default.nix +++ b/system/users/nathan/home-manager/programs/git/default.nix @@ -32,9 +32,9 @@ defaultBranch = "master"; }; url = { - "ssh://gitea@gitea.blunkall.us/" = { + "ssh://gitea@esotericbytes.com/" = { insteadOf = [ - "blunkall:" + "server:" ]; }; };