diff options
| author | m4siri <git@m4siri.com> | 2025-11-23 10:36:43 +0545 |
|---|---|---|
| committer | m4siri <git@m4siri.com> | 2025-11-23 10:36:56 +0545 |
| commit | 3424cfd40c046c038df0335212e8000ebd473602 (patch) | |
| tree | fc800399450284e77be346311952968591a5534e /flake.nix | |
repo init
Diffstat (limited to 'flake.nix')
| -rw-r--r-- | flake.nix | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..0a5e315 --- /dev/null +++ b/flake.nix @@ -0,0 +1,34 @@ +{ + inputs.nixpkgs.url = "github:NixOS/nixpkgs/release-25.05"; + inputs.nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable"; + inputs.disko.url = "github:nix-community/disko"; + inputs.disko.inputs.nixpkgs.follows = "nixpkgs"; + inputs.agenix.url = "github:ryantm/agenix"; + + outputs = { + nixpkgs, + nixpkgs-unstable, + disko, + agenix, + ... + } @ inputs: let + lib = nixpkgs.lib; + inherit (lib) filter hasSuffix; + listModules' = path: lib.filesystem.listFilesRecursive path |> filter (hasSuffix ".nix"); + unstable = import nixpkgs-unstable {system = "x86_64-linux";}; + in { + nixosConfigurations.experimental-nixos = nixpkgs.lib.nixosSystem rec { + system = "x86_64-linux"; + specialArgs = {inherit inputs unstable nixpkgs-unstable;}; + modules = + [ + disko.nixosModules.disko + agenix.nixosModules.default + ./hardware-configuration.nix + ] + ++ (listModules' modules/common) + ++ (listModules' hosts/experimental-nixos) + ++ (listModules' modules/disks/bcachefs); + }; + }; +} |
