From 4914c537cb649f73d4173aeb22e8fa65b8744a72 Mon Sep 17 00:00:00 2001 From: coolneng Date: Mon, 15 Mar 2021 12:06:30 +0100 Subject: [PATCH] Add hardware configuration --- modules/hardware-configuration.nix | 65 ++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 modules/hardware-configuration.nix diff --git a/modules/hardware-configuration.nix b/modules/hardware-configuration.nix new file mode 100644 index 0000000..2721931 --- /dev/null +++ b/modules/hardware-configuration.nix @@ -0,0 +1,65 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-amd" ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "system/stateful/root"; + fsType = "zfs"; + }; + + fileSystems."/nix" = + { device = "system/ephemeral/nix"; + fsType = "zfs"; + }; + + fileSystems."/home" = + { device = "system/stateful/home"; + fsType = "zfs"; + }; + + fileSystems."/tmp" = + { device = "system/ephemeral/tmp"; + fsType = "zfs"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/B314-22E9"; + fsType = "vfat"; + }; + + fileSystems."/vault" = + { device = "vault"; + fsType = "zfs"; + }; + + fileSystems."/vault/samba" = + { device = "vault/samba"; + fsType = "zfs"; + }; + + fileSystems."/vault/nextcloud" = + { device = "vault/nextcloud"; + fsType = "zfs"; + }; + + fileSystems."/vault/sica" = + { device = "vault/sica"; + fsType = "zfs"; + }; + + swapDevices = + [ { device = "/dev/disk/by-uuid/8262a243-b6aa-49e8-bf72-d2b85864d1c0"; } + ]; + +}