This commit is contained in:
2025-07-26 00:22:44 +09:00
parent 8c70aabc23
commit 7c39f4e13e
4 changed files with 25 additions and 48 deletions

1
.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
hardware-configuration.nix

View File

@@ -11,7 +11,7 @@
};
outputs = { self, nixpkgs, home-manager, ... }@inputs: {
nixosConfigurations.haskell = nixpkgs.lib.nixosSystem {
nixosConfigurations.monad = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [

View File

@@ -4,49 +4,27 @@
{ config, lib, pkgs, modulesPath, ... }:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules =
[ "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "uas" "sd_mod" ];
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelParams = [ "intel_iommu=on" ];
boot.kernelModules = [ "kvm-intel" "vfio_pci" ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
# 1050 passthrough
# boot.extraModprobeConfig = ''
# options vfio-pci ids=10de:1c81,10de:0fb9
# '';
fileSystems."/" =
{ device = "/dev/disk/by-uuid/f4bf5b26-3959-4087-ad60-b5eaaf9c7cd5";
fsType = "ext4";
};
fileSystems."/" = {
device = "/dev/disk/by-uuid/4e08142c-1b09-4265-a497-822e4a83d4c8";
fsType = "btrfs";
options = [ "subvol=root" ];
};
boot.initrd.luks.devices."luks-28e5a617-073a-4385-9fc2-f0620a8ead08".device = "/dev/disk/by-uuid/28e5a617-073a-4385-9fc2-f0620a8ead08";
fileSystems."/home" = {
device = "/dev/disk/by-uuid/4e08142c-1b09-4265-a497-822e4a83d4c8";
fsType = "btrfs";
options = [ "subvol=home" ];
};
fileSystems."/nix" = {
device = "/dev/disk/by-uuid/4e08142c-1b09-4265-a497-822e4a83d4c8";
fsType = "btrfs";
options = [ "subvol=nix" ];
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/E808-5876";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
fileSystems."/mnt/hdd1" = {
device = "/dev/disk/by-uuid/EC40940C4093DC20";
fsType = "ntfs-3g";
options = [ "rw" "uid=1000" "umask=0022" ];
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/40B6-4877";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
swapDevices = [ ];
@@ -55,10 +33,8 @@
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp5s0.useDHCP = lib.mkDefault true;
# networking.interfaces.eth0.useDHCP = lib.mkDefault true;
# networking.interfaces.wlo1.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View File

@@ -14,10 +14,10 @@
programs.virt-manager.enable = true;
services.k3s = {
enable = true;
clusterInit = true;
extraFlags =
"--cluster-cidr=10.42.0.0/16,2a10:3781:25ac:2::/64 --service-cidr=10.43.0.0/16,2a10:3781:25ac:3::/112 --flannel-iface enp5s0";
};
# services.k3s = {
# enable = true;
# clusterInit = true;
# extraFlags =
# "--cluster-cidr=10.42.0.0/16,2a10:3781:25ac:2::/64 --service-cidr=10.43.0.0/16,2a10:3781:25ac:3::/112 --flannel-iface enp5s0";
# };
}