diff --git a/flake.nix b/flake.nix index 6ec44df..daf0514 100644 --- a/flake.nix +++ b/flake.nix @@ -58,6 +58,7 @@ }; in { nixosConfigurations = { + # Microsoft Surface Laptop Go Dimaga = nixpkgs.lib.nixosSystem { system = "x86_64-linux"; modules = defaultModules.base ++ [ @@ -66,6 +67,7 @@ ]; }; + # Home server Haven = nixpkgs.lib.nixosSystem { system = "x86_64-linux"; modules = defaultModules.base ++ [ @@ -74,6 +76,16 @@ ]; }; + # Microsoft Surface Pro 7 + Khanda = nixpkgs.lib.nixosSystem { + system = "x86_64-linux"; + modules = defaultModules.base ++ [ + nixos-hardware.nixosModules.microsoft-surface-pro-intel + ./hosts/Khanda + ]; + }; + + # Raspberry Pi Pihole = nixpkgs.lib.nixosSystem { system = "aarch64-linux"; modules = defaultModules.base ++ [ @@ -82,6 +94,7 @@ ]; }; + # Lenovo Legion Slim 7 Gen 7 AMD Shura = nixpkgs.lib.nixosSystem { system = "x86_64-linux"; modules = defaultModules.base ++ [ diff --git a/hosts/Khanda/default.nix b/hosts/Khanda/default.nix new file mode 100644 index 0000000..9e05a84 --- /dev/null +++ b/hosts/Khanda/default.nix @@ -0,0 +1,46 @@ +{ pkgs, ... }: + +# Settings specific to Dimaga + +{ + imports = [ + ./hardware-configuration.nix + ../common + ]; + + system.stateVersion = "24.05"; + + host = { + role = "workstation"; + apps = { + development.enable = true; + kdeconnect.enable = true; + media.enable = true; + office.enable = true; + pandoc.enable = true; + }; + ui = { + flatpak.enable = true; + gnome.enable = true; + }; + users = { + aires = { + enable = true; + autologin = true; + services = { + syncthing = { + enable = true; + autostart = true; + enableTray = false; + }; + }; + }; + }; + }; + + # Configure the virtual machine created by nixos-rebuild build-vm + virtualisation.vmVariant.virtualisation = { + memorySize = 2048; + cores = 2; + }; +} diff --git a/hosts/Khanda/hardware-configuration.nix b/hosts/Khanda/hardware-configuration.nix new file mode 100644 index 0000000..758c3e7 --- /dev/null +++ b/hosts/Khanda/hardware-configuration.nix @@ -0,0 +1,44 @@ +# Surface Pro 7 +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = [ + (modulesPath + "/installer/scan/not-detected.nix") + ]; +/* + boot = { + initrd = { + availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "usbhid" "sd_mod" ]; + kernelModules = [ ]; + luks.devices."luks-5a91100b-8ed9-4090-b1d8-d8291000fe38".device = "/dev/disk/by-uuid/5a91100b-8ed9-4090-b1d8-d8291000fe38"; + }; + + kernelModules = [ "kvm-intel" ]; + extraModulePackages = [ ]; + }; + + fileSystems = { + "/" = { + device = "/dev/disk/by-uuid/76d67291-5aed-4f2a-b71f-1c2871cefe24"; + fsType = "btrfs"; + options = [ "subvol=@,compress=zstd" ]; + }; + "/boot" = { + device = "/dev/disk/by-uuid/0C53-A645"; + fsType = "vfat"; + }; + }; +*/ + swapDevices = [{ + device = "/swapfile"; + size = 4096; + }]; + + networking = { + useDHCP = lib.mkDefault true; + hostName = "Khanda"; + }; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +} diff --git a/hosts/default.nix b/hosts/default.nix index a926b57..4052ace 100644 --- a/hosts/default.nix +++ b/hosts/default.nix @@ -2,6 +2,7 @@ imports = [ ./Dimaga ./Haven + ./Khanda ./Pihole ./Shura ];