Created
December 14, 2025 09:32
-
-
Save GraemeF/70e1467b381a15271fbe298b61699764 to your computer and use it in GitHub Desktop.
NixOS config for dual boot with Omarchy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { config, pkgs, ... }: | |
| { | |
| imports = [ | |
| ./hardware-configuration.nix | |
| ]; | |
| boot.loader.systemd-boot.enable = true; | |
| boot.loader.efi.canTouchEfiVariables = true; | |
| boot.loader.efi.efiSysMountPoint = "/boot"; | |
| boot.loader.timeout = 0; | |
| boot.initrd.luks.devices."cryptroot" = { | |
| device = "/dev/disk/by-uuid/ac4acc0b-1417-44cf-8145-00daff20adfb"; | |
| preLVM = true; | |
| allowDiscards = true; | |
| }; | |
| networking.hostName = "nixos"; | |
| networking.networkmanager.enable = true; | |
| time.timeZone = "Australia/Sydney"; | |
| i18n.defaultLocale = "en_AU.UTF-8"; | |
| users.users.graeme = { | |
| isNormalUser = true; | |
| description = "Graeme"; | |
| extraGroups = [ "wheel" "networkmanager" ]; | |
| initialPassword = "changeme"; | |
| }; | |
| nixpkgs.config.allowUnfree = true; | |
| environment.systemPackages = with pkgs; [ | |
| vim git wget curl htop | |
| ]; | |
| services.openssh.enable = true; | |
| networking.firewall.enable = true; | |
| networking.firewall.allowedTCPPorts = [ 22 ]; | |
| system.stateVersion = "24.11"; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { config, lib, pkgs, modulesPath, ... }: | |
| { | |
| imports = [ | |
| (modulesPath + "/installer/scan/not-detected.nix") | |
| ]; | |
| boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "sd_mod" ]; | |
| boot.initrd.kernelModules = [ ]; | |
| boot.kernelModules = [ "kvm-amd" ]; | |
| boot.extraModulePackages = [ ]; | |
| fileSystems."/" = { | |
| device = "/dev/disk/by-uuid/8658615e-9026-4926-ae9a-eef75ca61124"; | |
| fsType = "btrfs"; | |
| options = [ "subvol=@nixos" "compress=zstd" "noatime" ]; | |
| }; | |
| fileSystems."/nix" = { | |
| device = "/dev/disk/by-uuid/8658615e-9026-4926-ae9a-eef75ca61124"; | |
| fsType = "btrfs"; | |
| options = [ "subvol=@nixos-nix" "compress=zstd" "noatime" ]; | |
| }; | |
| fileSystems."/home" = { | |
| device = "/dev/disk/by-uuid/8658615e-9026-4926-ae9a-eef75ca61124"; | |
| fsType = "btrfs"; | |
| options = [ "subvol=@nixos-home" "compress=zstd" "noatime" ]; | |
| }; | |
| fileSystems."/boot" = { | |
| device = "/dev/disk/by-uuid/29B0-FFC9"; | |
| fsType = "vfat"; | |
| options = [ "fmask=0077" "dmask=0077" ]; | |
| }; | |
| zramSwap.enable = true; | |
| zramSwap.memoryPercent = 25; | |
| nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; | |
| hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment