This commit is contained in:
2026-04-23 18:38:55 -05:00
parent ac32833239
commit dea26059eb
10 changed files with 117 additions and 132 deletions

View File

@@ -6,23 +6,16 @@
iso = [ "iso" ];
useWith = x: y: (lib.mkIf (builtins.any (z: z == config.networking.hostName) x) y);
in {
imports = [
inputs.sops-nix.nixosModules.sops
];
config = {
sops.secrets."nathan/pass" = {
neededForUsers = true;
sopsFile = ./secrets.yaml;
};
users.users.nathan = {
shell = pkgs.zsh;
name = lib.mkDefault "nathan";
isNormalUser = lib.mkDefault true;
hashedPasswordFile = lib.mkDefault config.sops.secrets."nathan/pass".path;
hashedPassword = lib.mkIf
(config.users.users.nathan.hashedPasswordFile == null)
"$y$j9T$F0pn6l4C45lz4a0FTZLqE0$Fc48Ptbmz/3MJCk/Jsaqop4ff.bY3J3GcjhmJx5R7k6";
extraGroups = [ "networkmanager" "docker" "libvirtd" "wheel" ];
openssh.authorizedKeys.keys = lib.mkMerge [
(useWith (homebox ++ iso) [
@@ -52,6 +45,7 @@
(useWith (laptop ++ iso) nathan-kitty)
(useWith (laptop ++ iso) nathan-scripts)
(useWith (laptop ++ iso) nathan-pywal)
(useWith (laptop ++ homebox) nathan-sops)
(useWith laptop {
wayland.windowManager.hyprland.extraConfig = ''
@@ -64,9 +58,17 @@
};
};
flake.homeModules.nathan-standalone = { lib, ... }:
flake.homeModules.nathan-sops = { ... }: {
imports = [
inputs.sops-nix.homeManagerModules.sops
];
config = {
sops.defaultSopsFile = ./secrets.yaml;
};
};
{
flake.homeModules.nathan-standalone = { ... }: {
config = {