summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--flake.nix12
-rw-r--r--system/prefect.nix7
2 files changed, 12 insertions, 7 deletions
diff --git a/flake.nix b/flake.nix
index 58a0dcb8..ad11212e 100644
--- a/flake.nix
+++ b/flake.nix
@@ -22,6 +22,7 @@
     , home-manager
     , nixpkgs
     , nix-index-database
+    , nixos-hardware
     , secrets
     , ...
     } @ attrs:
@@ -36,8 +37,15 @@
     {
       nixosConfigurations.prefect = nixpkgs.lib.nixosSystem {
         system = "x86_64-linux";
-        specialArgs = attrs;
-        modules = [ ./system/prefect.nix ];
+        modules = [
+          ./system/prefect.nix
+        ] ++ (with nixos-hardware.nixosModules; [
+          common-cpu-amd
+          common-cpu-amd-pstate
+          common-pc-ssd
+          common-pc
+          common-gpu-nvidia-nonprime
+        ]);
       };
       nixosConfigurations.nanopi = nixpkgs.lib.nixosSystem {
         system = aarch64LinuxSystem;
diff --git a/system/prefect.nix b/system/prefect.nix
index fa57ef36..d3e1359e 100644
--- a/system/prefect.nix
+++ b/system/prefect.nix
@@ -1,13 +1,8 @@
 { config
 , pkgs
-, nixos-hardware
 , ...
 }: {
   imports = [
-    (nixos-hardware + "/common/pc/ssd")
-    (nixos-hardware + "/common/cpu/amd")
-    (nixos-hardware + "/common/cpu/amd/pstate.nix")
-
     ./settings/base.nix
     ./settings/configuration/berlin.nix
     ./settings/configuration/british-english.nix
@@ -31,6 +26,8 @@
     ./settings/gaming.nix
   ];
 
+  nixpkgs.hostPlatform = "x86_64-linux";
+
   services.xserver.screenSection = ''
     Option "MetaModes" "2560x1440_165 +0+0 { ForceCompositionPipeline=On }"
   '';