diff --git a/config/waybar/style.css b/config/waybar/style.css index d5fac5b..d50fc88 100644 --- a/config/waybar/style.css +++ b/config/waybar/style.css @@ -7,7 +7,8 @@ } window#waybar { - background-color: @base; + background-color: rgba(0, 0, 0, 0); + margin-top: 5px; color: @text; transition-property: background-color; transition-duration: .5s; @@ -85,7 +86,8 @@ label:focus { #language, #battery, #clock, -#tray { +#tray, +#window { background-color: @mantle; padding: 5px; margin: 3px; diff --git a/configuration.nix b/configuration.nix index b28c502..eee6997 100644 --- a/configuration.nix +++ b/configuration.nix @@ -58,11 +58,11 @@ "/var/log" "/var/lib/bluetooth" "/var/lib/nixos" - # "/var/lib/libvirt" - # "/var/lib/ollama-models" - # "/var/lib/flatpak" + "/var/lib/libvirt" + "/var/lib/ollama-models" + "/var/lib/flatpak" "/var/lib/tailscale" - # "/var/lib/syncthing" + "/var/lib/syncthing" "/etc/NetworkManager/system-connections" "/etc/ssh" ]; @@ -119,7 +119,7 @@ enable = true; wrappedBinaries = { vesktop = { - executable = "${pkgs-stable.vesktop}/bin/vesktop"; + executable = "${pkgs.vesktop}/bin/vesktop"; profile = "${pkgs.firejail}/etc/firejail/vesktop.profile"; extraArgs = [ "--ignore=dbus-system" @@ -149,6 +149,26 @@ "--env=GTK_THEME=Adwaita:dark" ]; }; + signal-desktop-bin = { + executable = "${pkgs.signal-desktop-bin}/bin/signal-desktop"; + profile = "${pkgs.firejail}/etc/firejail/signal-desktop.profile"; + extraArgs = [ + "--env=GTK_THEME=Adwaita:dark" + "--noblacklist=~/Pictures" + "--noblacklist=~/Documents" + "--whitelist=~/Pictures" + "--whitelist=~/Documents" + "--dbus-user.talk=org.freedesktop.Notifications" + "--dbus-user.talk=org.kde.StatusNotifierWatcher" + ]; + }; + obsidian = { + executable = "${pkgs.obsidian}/bin/obsidian"; + profile = "${pkgs.firejail}/etc/firejail/obsidian.profile"; + extraArgs = [ + "--env=GTK_THEME=Adwaita:dark" + ]; + }; }; }; @@ -161,11 +181,11 @@ # Enable Hyprland. programs.hyprland.enable = true; - # services.flatpak.enable = true; + services.flatpak.enable = true; # Enable CUPS to print documents. - # services.printing.enable = true; - # services.printing.drivers = [ pkgs.hplip ]; + services.printing.enable = true; + services.printing.drivers = [ pkgs.hplip ]; programs.gnupg.agent.enable = true; @@ -201,8 +221,8 @@ enable32Bit = true; }; - # services.ollama.enable = true; - # services.ollama.models = "/var/lib/ollama-models"; + services.ollama.enable = true; + services.ollama.models = "/var/lib/ollama-models"; # Enable automatic login for the user. # We temporarily keep this enabled because I plan to switch to LVM on LUKS. @@ -224,12 +244,32 @@ git ]; + programs.steam.enable = true; + nix.gc = { automatic = true; dates = "weekly"; options = "--delete-older-than 2d"; }; + programs.virt-manager.enable = true; + virtualisation.libvirtd = { + enable = true; + qemu = { + vhostUserPackages = with pkgs; [ virtiofsd ]; + swtpm.enable = true; + }; + }; + virtualisation.spiceUSBRedirection.enable = true; + virtualisation.docker.enable = true; + + services = { + syncthing = { + enable = true; + group = "users"; + user = "xory"; + }; + }; services.openssh.enable = true; # TODO: add declarative key-based auth # Some programs need SUID wrappers, can be configured further or are @@ -243,8 +283,8 @@ # List services that you want to enable: # Open ports in the firewall. - networking.firewall.allowedTCPPorts = [ 8000 8080 25565 ]; - networking.firewall.allowedUDPPorts = [ 8000 8080 ]; + networking.firewall.allowedTCPPorts = [ 8000 8080 25565 5173 5174 ]; + networking.firewall.allowedUDPPorts = [ 8000 8080 5173 5174 ]; # Or disable the firewall altogether. # networking.firewall.enable = false; nix.settings.experimental-features = [ "nix-command" "flakes" ]; diff --git a/flake.lock b/flake.lock index 518618c..d08d2e3 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1766150702, - "narHash": "sha256-P0kM+5o+DKnB6raXgFEk3azw8Wqg5FL6wyl9jD+G5a4=", + "lastModified": 1771469470, + "narHash": "sha256-GnqdqhrguKNN3HtVfl6z+zbV9R9jhHFm3Z8nu7R6ml0=", "owner": "nix-community", "repo": "disko", - "rev": "916506443ecd0d0b4a0f4cf9d40a3c22ce39b378", + "rev": "4707eec8d1d2db5182ea06ed48c820a86a42dc13", "type": "github" }, "original": { @@ -20,6 +20,24 @@ "type": "github" } }, + "flake-utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1731533236, + "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -27,11 +45,32 @@ ] }, "locked": { - "lastModified": 1767437240, - "narHash": "sha256-OA0dBHhccdupFXp+/eaFfb8K1dQxk61in4aF5ITGVX8=", + "lastModified": 1771756436, + "narHash": "sha256-Tl2I0YXdhSTufGqAaD1ySh8x+cvVsEI1mJyJg12lxhI=", "owner": "nix-community", "repo": "home-manager", - "rev": "1cfa305fba94468f665de1bd1b62dddf2e0cb012", + "rev": "5bd3589390b431a63072868a90c0f24771ff4cbb", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "home-manager", + "type": "github" + } + }, + "home-manager_2": { + "inputs": { + "nixpkgs": [ + "impermanence", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1768598210, + "narHash": "sha256-kkgA32s/f4jaa4UG+2f8C225Qvclxnqs76mf8zvTVPg=", + "owner": "nix-community", + "repo": "home-manager", + "rev": "c47b2cc64a629f8e075de52e4742de688f930dc6", "type": "github" }, "original": { @@ -41,12 +80,16 @@ } }, "impermanence": { + "inputs": { + "home-manager": "home-manager_2", + "nixpkgs": "nixpkgs" + }, "locked": { - "lastModified": 1737831083, - "narHash": "sha256-LJggUHbpyeDvNagTUrdhe/pRVp4pnS6wVKALS782gRI=", + "lastModified": 1769548169, + "narHash": "sha256-03+JxvzmfwRu+5JafM0DLbxgHttOQZkUtDWBmeUkN8Y=", "owner": "nix-community", "repo": "impermanence", - "rev": "4b3e914cdf97a5b536a889e939fb2fd2b043a170", + "rev": "7b1d382faf603b6d264f58627330f9faa5cba149", "type": "github" }, "original": { @@ -55,13 +98,35 @@ "type": "github" } }, + "nix4nvchad": { + "inputs": { + "flake-utils": "flake-utils", + "nixpkgs": [ + "nixpkgs" + ], + "nvchad-starter": "nvchad-starter" + }, + "locked": { + "lastModified": 1771479716, + "narHash": "sha256-px2OOCb6VDEGNSVpFEbVLnocz34qrfAarx28lTzrWsw=", + "owner": "nix-community", + "repo": "nix4nvchad", + "rev": "5098052557a36a148c84740733c4ac5b1bc566a5", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "nix4nvchad", + "type": "github" + } + }, "nixos-hardware": { "locked": { - "lastModified": 1767185284, - "narHash": "sha256-ljDBUDpD1Cg5n3mJI81Hz5qeZAwCGxon4kQW3Ho3+6Q=", + "lastModified": 1771423359, + "narHash": "sha256-yRKJ7gpVmXbX2ZcA8nFi6CMPkJXZGjie2unsiMzj3Ig=", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "40b1a28dce561bea34858287fbb23052c3ee63fe", + "rev": "740a22363033e9f1bb6270fbfb5a9574067af15b", "type": "github" }, "original": { @@ -72,11 +137,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1767379071, - "narHash": "sha256-EgE0pxsrW9jp9YFMkHL9JMXxcqi/OoumPJYwf+Okucw=", + "lastModified": 1768564909, + "narHash": "sha256-Kell/SpJYVkHWMvnhqJz/8DqQg2b6PguxVWOuadbHCc=", "owner": "nixos", "repo": "nixpkgs", - "rev": "fb7944c166a3b630f177938e478f0378e64ce108", + "rev": "e4bae1bd10c9c57b2cf517953ab70060a828ee6f", "type": "github" }, "original": { @@ -88,11 +153,11 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1767325753, - "narHash": "sha256-yA/CuWyqm+AQo2ivGy6PlYrjZBQm7jfbe461+4HF2fo=", + "lastModified": 1771714954, + "narHash": "sha256-nhZJPnBavtu40/L2aqpljrfUNb2rxmWTmSjK2c9UKds=", "owner": "nixos", "repo": "nixpkgs", - "rev": "64049ca74d63e971b627b5f3178d95642e61cedd", + "rev": "afbbf774e2087c3d734266c22f96fca2e78d3620", "type": "github" }, "original": { @@ -104,11 +169,27 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1766651565, - "narHash": "sha256-QEhk0eXgyIqTpJ/ehZKg9IKS7EtlWxF3N7DXy42zPfU=", + "lastModified": 1771369470, + "narHash": "sha256-0NBlEBKkN3lufyvFegY4TYv5mCNHbi5OmBDrzihbBMQ=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "0182a361324364ae3f436a63005877674cf45efb", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_3": { + "locked": { + "lastModified": 1771369470, + "narHash": "sha256-0NBlEBKkN3lufyvFegY4TYv5mCNHbi5OmBDrzihbBMQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "3e2499d5539c16d0d173ba53552a4ff8547f4539", + "rev": "0182a361324364ae3f436a63005877674cf45efb", "type": "github" }, "original": { @@ -118,28 +199,46 @@ "type": "github" } }, + "nvchad-starter": { + "flake": false, + "locked": { + "lastModified": 1753939018, + "narHash": "sha256-xdLr6tlU9uA+wu0pqha2br0fdVm+1MjgjbB5awz9ICU=", + "owner": "NvChad", + "repo": "starter", + "rev": "e3572e1f5e1c297212c3deeb17b7863139ce663e", + "type": "github" + }, + "original": { + "owner": "NvChad", + "ref": "main", + "repo": "starter", + "type": "github" + } + }, "root": { "inputs": { "disko": "disko", "home-manager": "home-manager", "impermanence": "impermanence", + "nix4nvchad": "nix4nvchad", "nixos-hardware": "nixos-hardware", - "nixpkgs": "nixpkgs", + "nixpkgs": "nixpkgs_2", "nixpkgs-stable": "nixpkgs-stable", "spicetify-nix": "spicetify-nix" } }, "spicetify-nix": { "inputs": { - "nixpkgs": "nixpkgs_2", - "systems": "systems" + "nixpkgs": "nixpkgs_3", + "systems": "systems_2" }, "locked": { - "lastModified": 1767195736, - "narHash": "sha256-0xvPSbhIGeJzsJXNTkgJ3PjwdVItKm85wzYKA9NmSzI=", + "lastModified": 1771737804, + "narHash": "sha256-7wn9qbzIQQgH8tnq4VwzuWEqEWpekuymlLyhY3vM/j8=", "owner": "Gerg-L", "repo": "spicetify-nix", - "rev": "465adc0ab6ff0c4b9b1db1c6e7fd7eeb553b3261", + "rev": "6dd43010ac2458cc56a6ac5250349b9217a7a2ae", "type": "github" }, "original": { @@ -162,6 +261,21 @@ "repo": "default", "type": "github" } + }, + "systems_2": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } } }, "root": "root", diff --git a/flake.nix b/flake.nix index c85379c..979ad72 100644 --- a/flake.nix +++ b/flake.nix @@ -12,10 +12,14 @@ home-manager.url = "github:nix-community/home-manager"; home-manager.inputs.nixpkgs.follows = "nixpkgs"; - - impermanence.url = "github:nix-community/impermanence"; + impermanence.url = "github:nix-community/impermanence"; spicetify-nix.url = "github:Gerg-L/spicetify-nix"; + + nix4nvchad = { + url = "github:nix-community/nix4nvchad"; + inputs.nixpkgs.follows = "nixpkgs"; + }; }; outputs = diff --git a/home.nix b/home.nix index aa6ad14..3fb19eb 100644 --- a/home.nix +++ b/home.nix @@ -1,17 +1,47 @@ { config, pkgs, inputs, ... }: { + imports = [ inputs.spicetify-nix.homeManagerModules.default inputs.nix4nvchad.homeManagerModule ]; home.username = "xory"; home.homeDirectory = "/home/xory"; home.packages = with pkgs; [ - neovim + # neovim fastfetch git cava kdePackages.qtwebsockets + (python313.withPackages (python-pkgs: [ + python313Packages.requests # basic python test env + ])) + simplex-chat-desktop + qbittorrent + ffmpeg + yt-dlp + prismlauncher keepassxc + (wrapOBS { + plugins = with pkgs.obs-studio-plugins; [ + obs-vaapi + obs-gstreamer + obs-vkcapture + wlrobs + obs-pipewire-audio-capture + ]; + }) + mpv + gimp + inkscape + krita + distrobox screen + arduino-ide + (lutris.override { + extraLibraries = pkgs: [ + wineWow64Packages.stable + winetricks + ]; + }) libadwaita # fucking winetricks zenity woeusb-ng @@ -20,19 +50,23 @@ hyprsunset grim slurp + input-leap + viber hyprpolkitagent pulsemixer feh + opentrack + aitrack progress croc libarchive ]; home.file = { - ".config/nvim/init.lua" = { - enable = true; - source = ./config/nvim/init.lua; - }; + # ".config/nvim/init.lua" = { + # enable = true; + # source = ./config/nvim/init.lua; + # }; ".config/hypr" = { enable = true; recursive = true; @@ -75,6 +109,43 @@ eval "$(direnv hook zsh)" settings.window_padding_width = 5; }; + programs.spicetify = + let + spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.stdenv.hostPlatform.system}; + in + { + enable = true; + + theme = spicePkgs.themes.catppuccin; + colorScheme = "mocha"; + + enabledExtensions = with spicePkgs.extensions; [ + hidePodcasts + shuffle + betterGenres + beautifulLyrics + ]; + + enabledCustomApps = with spicePkgs.apps; [ + newReleases + ncsVisualizer + ]; + }; + + # firejail + xdg.desktopEntries.spotify = { + name = "Spotify"; + genericName = "Music Player"; + icon = "spotify-client"; + exec = "${pkgs.firejail}/bin/firejail ${config.programs.spicetify.spicedSpotify}/bin/spotify %U"; + terminal = false; + categories = [ "Audio" "Music" "Player" "AudioVideo" ]; + mimeType = [ "x-scheme-handler/spotify" ]; + }; + + programs.nvchad.enable = true; + programs.vscode.enable = true; + wayland.windowManager.hyprland.enable = true; programs.waybar.enable = true; programs.wofi.enable = true; diff --git a/hosts/nullstar/config.nix b/hosts/nullstar/config.nix new file mode 100644 index 0000000..6e5a043 --- /dev/null +++ b/hosts/nullstar/config.nix @@ -0,0 +1,31 @@ +{ config, pkgs, pkgs-stable, lib, inputs, ... }: + +{ + imports = + [ + ./hardware/hardware-configuration.nix + ./hardware/disko.nix + (inputs.nixos-hardware.nixosModules.framework-16-7040-amd) + ]; + + services.fwupd.enable = true; + + networking.hostName = "nullstar"; + networking.hostId = "322d5212"; + + # Enable FL16 Input modules + hardware.inputmodule.enable = true; + hardware.keyboard.qmk.enable = true; + + hardware.graphics.extraPackages = with pkgs; [ + libvdpau-va-gl + rocmPackages.clr.icd + ]; + + services.ollama.package = pkgs-stable.ollama-rocm; + + environment.systemPackages = with pkgs; [ + framework-tool + inputmodule-control + ]; +} diff --git a/hosts/nullstar/hardware/disko.nix b/hosts/nullstar/hardware/disko.nix new file mode 100644 index 0000000..b4e0acd --- /dev/null +++ b/hosts/nullstar/hardware/disko.nix @@ -0,0 +1,96 @@ +{ + disko.devices = { + disk = { + main = { + type = "disk"; + device = "/dev/nvme0n1"; + content = { + type = "gpt"; + partitions = { + ESP = { + size = "512M"; + type = "EF00"; + content = { + type = "filesystem"; + format = "vfat"; + mountpoint = "/boot"; + mountOptions = [ "umask=0077" ]; + }; + }; + luks = { + size = "100%"; + content = { + type = "luks"; + name = "crypted"; + # Disable this if you do not want to allow TRIM requests to pass through LUKS + # (Security vs SSD longevity trade-off) + settings.allowDiscards = true; + # Uncomment if you want to use a keyfile during install: + # settings.keyFile = "/tmp/secret.key"; + content = { + type = "zfs"; + pool = "zroot"; + }; + }; + }; + }; + }; + }; + }; + zpool = { + zroot = { + type = "zpool"; + options = { + ashift = "12"; + autotrim = "on"; + }; + rootFsOptions = { + acltype = "posixacl"; + xattr = "sa"; + dnodesize = "auto"; + compression = "zstd"; + normalization = "formD"; + relatime = "on"; + canmount = "off"; + # Prevent auto-snapshotting by default (enable explicitly on datasets that need it) + "com.sun:auto-snapshot" = "false"; + }; + datasets = { + # The ephemeral root dataset. + # We create a blank snapshot immediately so you can rollback to it on boot. + "root" = { + type = "zfs_fs"; + mountpoint = "/"; + options.mountpoint = "legacy"; + postCreateHook = "zfs snapshot zroot/root@blank"; + }; + + # The Nix Store (reproducible, doesn't need backing up usually) + "nix" = { + type = "zfs_fs"; + mountpoint = "/nix"; + options.mountpoint = "legacy"; + options."com.sun:auto-snapshot" = "false"; + }; + + # Persisted state (for impermanence) + "persist" = { + type = "zfs_fs"; + mountpoint = "/persist"; + options.mountpoint = "legacy"; + # Enable snapshots for data safety if using sanoid/syncoid + # options."com.sun:auto-snapshot" = "true"; + }; + + # Home directories + "home" = { + type = "zfs_fs"; + mountpoint = "/home"; + options.mountpoint = "legacy"; + # options."com.sun:auto-snapshot" = "true"; + }; + }; + }; + }; + }; +} diff --git a/hosts/nullstar/hardware/hardware-configuration.nix b/hosts/nullstar/hardware/hardware-configuration.nix new file mode 100644 index 0000000..72e9c1e --- /dev/null +++ b/hosts/nullstar/hardware/hardware-configuration.nix @@ -0,0 +1,23 @@ +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "thunderbolt" "usb_storage" "usbhid" "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-amd" ]; + boot.extraModulePackages = [ ]; + + # Enables DHCP on each ethernet and wireless interface. In case of scripted networking + # (the default) this is the recommended approach. When using systemd-networkd it's + # still possible to use this option, but it's recommended to use it in conjunction + # with explicit per-interface declarations with `networking.interfaces..useDHCP`. + networking.useDHCP = lib.mkDefault true; + # networking.interfaces.enp42s0.useDHCP = lib.mkDefault true; + # networking.interfaces.wlo1.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +} diff --git a/hosts/voidspear/config.nix b/hosts/voidspear/config.nix new file mode 100644 index 0000000..31173ec --- /dev/null +++ b/hosts/voidspear/config.nix @@ -0,0 +1,28 @@ +{ config, pkgs, lib, inputs, ... }: + +{ + imports = [ + ./hardware/hardware-configuration.nix + ./hardware/disko.nix + ]; + + networking.hostName = "voidspear"; + networking.hostID = "ec82a76e"; + + + # nVidia drivers. + hardware.graphics.extraPackages = with pkgs; [ + libvdpau-va-gl + ]; + services.xserver.videoDrivers = [ "nvidia"]; + hardware.nvidia = { + modesetting.enable = true; + powerManagement.enable = false; + open = false; + nvidiaSettings = true; + package = config.boot.kernelPackages.nvidiaPackages.stable; + }; + boot.blacklistedKernelModules = [ "nouveau" ]; + + services.ollama.package = pkgs.ollama-cuda; +} diff --git a/hosts/voidspear/hardware/disko.nix b/hosts/voidspear/hardware/disko.nix new file mode 100644 index 0000000..fc8c217 --- /dev/null +++ b/hosts/voidspear/hardware/disko.nix @@ -0,0 +1,88 @@ +{ + disko.devices = { + disk = { + main = { + type = "disk"; + device = "/dev/nvme0n1"; + content = { + type = "gpt"; + partitions = { + ESP = { + size = "512M"; + type = "EF00"; + content = { + type = "filesystem"; + format = "vfat"; + mountpoint = "/boot"; + mountOptions = [ "umask=0077" ]; + }; + }; + luks = { + size = "100%"; + content = { + type = "luks"; + name = "crypted"; + # Critical for Samsung NVMe longevity/performance + settings.allowDiscards = true; + content = { + type = "zfs"; + pool = "zroot"; + }; + }; + }; + }; + }; + }; + }; + zpool = { + zroot = { + type = "zpool"; + options = { + ashift = "12"; + autotrim = "on"; + }; + rootFsOptions = { + acltype = "posixacl"; + xattr = "sa"; + dnodesize = "auto"; + compression = "zstd"; + normalization = "formD"; + relatime = "on"; + canmount = "off"; + "com.sun:auto-snapshot" = "false"; + }; + datasets = { + # Ephemeral root (rolls back to blank on boot) + "root" = { + type = "zfs_fs"; + mountpoint = "/"; + options.mountpoint = "legacy"; + postCreateHook = "zfs snapshot zroot/root@blank"; + }; + + # Nix store + "nix" = { + type = "zfs_fs"; + mountpoint = "/nix"; + options.mountpoint = "legacy"; + options."com.sun:auto-snapshot" = "false"; + }; + + # Persistent data + "persist" = { + type = "zfs_fs"; + mountpoint = "/persist"; + options.mountpoint = "legacy"; + }; + + # Home directories + "home" = { + type = "zfs_fs"; + mountpoint = "/home"; + options.mountpoint = "legacy"; + }; + }; + }; + }; + }; +} diff --git a/hosts/voidspear/hardware/hardware-configuration.nix b/hosts/voidspear/hardware/hardware-configuration.nix new file mode 100644 index 0000000..53f8354 --- /dev/null +++ b/hosts/voidspear/hardware/hardware-configuration.nix @@ -0,0 +1,23 @@ +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-amd" ]; + boot.extraModulePackages = [ ]; + + # Enables DHCP on each ethernet and wireless interface. In case of scripted networking + # (the default) this is the recommended approach. When using systemd-networkd it's + # still possible to use this option, but it's recommended to use it in conjunction + # with explicit per-interface declarations with `networking.interfaces..useDHCP`. + networking.useDHCP = lib.mkDefault true; + # networking.interfaces.enp42s0.useDHCP = lib.mkDefault true; + # networking.interfaces.wlo1.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +}