about summary refs log tree commit diff stats
path: root/flake
diff options
context:
space:
mode:
Diffstat (limited to 'flake')
-rw-r--r--flake/nixosConfigurations/default.nix83
1 files changed, 75 insertions, 8 deletions
diff --git a/flake/nixosConfigurations/default.nix b/flake/nixosConfigurations/default.nix
index f2110eb9..3895593f 100644
--- a/flake/nixosConfigurations/default.nix
+++ b/flake/nixosConfigurations/default.nix
@@ -1,24 +1,91 @@
 {
+  self,
   system,
-  pkgs,
+  myPkgs,
   nixpkgs_as_input,
-  # configs
-  defaultModules,
-  defaultSpecialArgs,
-  ...
+  nixpkgs_open_prs,
+  # my things
+  shell_library,
+  sysLib,
+  templates,
+  # modules
+  home-manager,
+  nixVim,
+  nixos-generators,
+  impermanence,
+  agenix,
+  ragenix,
+  serverphone,
+  disko,
+  lanzaboote,
+  nix-index-database,
+  # bins
+  river_init_lesser,
+  yambar_cpu,
+  yambar_memory,
+  # external
+  user_js,
 }: let
+  modules = [
+    "${nixpkgs_open_prs.nixpkgs-tfc}/nixos/modules/config/xdg/portals/termfilechooser.nix"
+
+    agenix.nixosModules.default
+    disko.nixosModules.default
+    home-manager.nixosModules.home-manager
+    impermanence.nixosModules.impermanence
+    lanzaboote.nixosModules.lanzaboote
+    serverphone.nixosModules.default
+
+    # Deduplicate some code in the host files
+    ../../modules/system
+  ];
+
+  specialArgs = {
+    inherit
+      # extra package sources
+      nixpkgs_open_prs
+      myPkgs
+      shell_library
+      sysLib
+      # extra information
+
+      system
+      # modules
+
+      impermanence
+      nix-index-database
+      nixVim
+      # nix registry
+
+      nixpkgs_as_input
+      self
+      templates
+      # bins
+
+      # TODO: Integrate these into `pkgs/by-name` <2024-05-22>
+
+      river_init_lesser
+      serverphone
+      yambar_cpu
+      yambar_memory
+      # external deps
+
+      user_js
+      ;
+  };
+
   generateHost = name: {
     name = "${name}";
     value = nixpkgs_as_input.lib.nixosSystem {
-      inherit system pkgs;
-      specialArgs = defaultSpecialArgs;
+      inherit specialArgs;
       modules =
         [
           ../../hosts/${name}
         ]
-        ++ defaultModules;
+        ++ modules;
     };
   };
+
   # FIXME: These need to stay in this position for the install script
   hosts = ["tiamat" "apzu"];
   inactiveHosts = ["mammun" "lahmu"];