diff --git a/hosts/mabon/home/default.nix b/hosts/mabon/home/default.nix new file mode 100644 index 00000000..c915eb0a --- /dev/null +++ b/hosts/mabon/home/default.nix @@ -0,0 +1 @@ +{ ... }: { } diff --git a/hosts/mabon/meta.nix b/hosts/mabon/meta.nix new file mode 100644 index 00000000..0e47ee5d --- /dev/null +++ b/hosts/mabon/meta.nix @@ -0,0 +1,18 @@ +{ config, hosts, ... }: { + config = { + resources.mabon = { + provider = "null"; + type = "resource"; + connection = { + port = 62954; + host = "192.168.1.119"; + }; + }; + deploy.systems.mabon = with config.resources; { + nixosConfig = hosts.mabon.config; + connection = mabon.connection.set; + triggers.copy.mabon = mabon.refAttr "id"; + triggers.secrets.mabon = mabon.refAttr "id"; + }; + }; +} diff --git a/hosts/mabon/nixos/default.nix b/hosts/mabon/nixos/default.nix new file mode 100644 index 00000000..70d84f03 --- /dev/null +++ b/hosts/mabon/nixos/default.nix @@ -0,0 +1,31 @@ + +{ config, pkgs, profiles, ... }: + +{ + imports = [ + ./hw.nix + profiles.gui + profiles.sway + profiles.kat + profiles.laptop + ]; + + deploy.target = "mbp"; + + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; + + boot.kernelPackages = pkgs.linuxPackages; + boot.kernelModules = [ "wl" ]; + boot.extraModulePackages = [ config.boot.kernelPackages.broadcom_sta ]; + + networking.hostId = "d199ad70"; + networking.hostName = "mabon"; + + networking.useDHCP = false; + networking.interfaces.enp1s0.useDHCP = true; + networking.interfaces.wlp2s0.useDHCP = true; + networking.networkmanager.enable = true; + + system.stateVersion = "20.09"; +} diff --git a/hosts/mabon/nixos/hw.nix b/hosts/mabon/nixos/hw.nix new file mode 100644 index 00000000..72f7f165 --- /dev/null +++ b/hosts/mabon/nixos/hw.nix @@ -0,0 +1,30 @@ +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ahci" "firewire_ohci" "usbhid" "usb_storage" "sd_mod" "sr_mod" "sdhci_pci" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-intel" "wl" ]; + boot.extraModulePackages = [ config.boot.kernelPackages.broadcom_sta ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/236f9363-19ee-46e3-8db4-5dd1e28b742d"; + fsType = "ext4"; + }; + + boot.initrd.luks.devices."cryptroot".device = "/dev/disk/by-uuid/b0435b6c-fd76-44d0-8b63-2c2c059df814"; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/84FB-4F88"; + fsType = "vfat"; + }; + + swapDevices = + [ { device = "/dev/disk/by-uuid/926c41d6-c06a-4dcc-b55d-f4cfaafe4bac"; } + ]; + + powerManagement.cpuFreqGovernor = lib.mkDefault "powersave"; +}