add sops + sops-nix

This commit is contained in:
Daylin Morgan 2024-11-28 17:35:38 -06:00
parent 67459a9e80
commit dba19e95f0
Signed by: daylin
GPG key ID: 950D13E9719334AD
4 changed files with 39 additions and 15 deletions

View file

@ -915,11 +915,32 @@
"nixpkgs": "nixpkgs_4",
"nixpkgs-wayland": "nixpkgs-wayland",
"pixi": "pixi",
"sops-nix": "sops-nix",
"stable": "stable",
"tsm": "tsm",
"utils": "utils"
}
},
"sops-nix": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1732575825,
"narHash": "sha256-xtt95+c7OUMoqZf4OvA/7AemiH3aVuWHQbErYQoPwFk=",
"owner": "Mic92",
"repo": "sops-nix",
"rev": "3433ea14fbd9e6671d0ff0dd45ed15ee4c156ffa",
"type": "github"
},
"original": {
"owner": "Mic92",
"repo": "sops-nix",
"type": "github"
}
},
"stable": {
"locked": {
"lastModified": 1732632634,

View file

@ -16,6 +16,11 @@
inputs.nixpkgs.follows = "nixpkgs";
};
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
lix = {
url = "https://git.lix.systems/lix-project/lix/archive/main.tar.gz";
flake = false;

View file

@ -7,7 +7,7 @@
]
++ (with pkgs; [
sops
distrobox
zk
quarto

View file

@ -17,13 +17,15 @@ let
listify
;
inherit (lib.filesystem) listFilesRecursive;
flake = flakeFromSystem "x86_64-linux";
hostPath = host: ../. + "/hosts/${host}";
# all nix files not including pkgs.nix
# hostFiles = host: filter isNixFile (listFilesRecursive (hostPath host));
hostFiles = host: host |> hostPath |> listFilesRecursive |> filter isNixFile;
nixosModules = names: names |> listify |> map (n: inputs.${n}.nixosModules.default);
selfModules = names: names |> listify |> map (n: self.nixosModules.${n});
commonSpecialArgs = {
inherit
self
@ -35,12 +37,7 @@ let
mkIso = nixosSystem {
system = "x86_64-linux";
modules = [
inputs.lix-module.nixosModules.default
self.nixosModules.nix
self.nixosModules.essentials
self.nixosModules.iso
];
modules = (nixosModules "lix-module") ++ (selfModules "nix|essentials|iso");
specialArgs = commonSpecialArgs;
};
@ -48,12 +45,13 @@ let
hostName:
nixosSystem {
system = "x86_64-linux";
modules = [
../modules/oizys.nix
inputs.lix-module.nixosModules.default
inputs.hyprland.nixosModules.default
modules =
[
inputs.comin.nixosModules.comin
] ++ (hostFiles hostName);
]
++ (selfModules ''oizys'')
++ (nixosModules ''lix-module|hyprland|sops-nix'')
++ (hostFiles hostName);
specialArgs = commonSpecialArgs // {
inherit