2023-06-09 23:07:50 +02:00
|
|
|
{ my, ... }:
|
2023-06-08 21:38:44 +02:00
|
|
|
|
|
|
|
{
|
|
|
|
imports = [ ../system/desktop.nix ../system/ucode-amd.nix ];
|
|
|
|
|
2023-07-24 00:54:35 +02:00
|
|
|
nixpkgs.overlays = [
|
|
|
|
# Newer linux-firmware releases contain some firmware which has some firmware that is
|
|
|
|
# apparently not handled correctly by the amdgpu driver, at least for this IP version present
|
|
|
|
# on the iGPU.
|
|
|
|
# See https://github.com/torvalds/linux/blob/b5641a5d8b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c#L1591
|
|
|
|
(_: super: {
|
|
|
|
linux-firmware = super.linux-firmware.overrideAttrs (_: rec {
|
|
|
|
version = "20230404";
|
|
|
|
src = super.fetchzip {
|
|
|
|
url =
|
|
|
|
"https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/snapshot/linux-firmware-${version}.tar.gz";
|
|
|
|
hash = "sha256-HZ2uU8BQKTkDup19mzhf67u48aFVyQfGQSVlCqFPWsk=";
|
|
|
|
};
|
|
|
|
outputHash = "sha256-CHD/MRut/0yjPuG+hH2gsbTR/Dhk4DbWfHsCbsg1oX8=";
|
|
|
|
});
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2023-06-08 21:38:44 +02:00
|
|
|
system.stateVersion = "23.05";
|
|
|
|
|
|
|
|
boot.initrd.availableKernelModules =
|
|
|
|
[ "xhci_pci" "nvme" "usb_storage" "sd_mod" ];
|
2023-06-14 16:33:41 +02:00
|
|
|
|
|
|
|
boot.blacklistedKernelModules = [ "acpi_cpufreq" ];
|
|
|
|
boot.kernelParams = [ "amd_pstate=active" "amdgpu.sg_display=0" ];
|
2023-06-08 21:38:44 +02:00
|
|
|
|
|
|
|
fileSystems."/boot" = {
|
|
|
|
device = "/dev/disk/by-uuid/B369-D2FE";
|
|
|
|
fsType = "vfat";
|
|
|
|
};
|
|
|
|
|
|
|
|
fileSystems."/" = {
|
|
|
|
device = "/dev/disk/by-uuid/5151f79a-fca4-45d4-8bd9-66f157a1d51f";
|
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@" ];
|
|
|
|
};
|
|
|
|
|
|
|
|
fileSystems."/home" = {
|
|
|
|
device = "/dev/disk/by-uuid/5151f79a-fca4-45d4-8bd9-66f157a1d51f";
|
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@home" ];
|
|
|
|
};
|
|
|
|
|
|
|
|
fileSystems."/nix" = {
|
|
|
|
device = "/dev/disk/by-uuid/5151f79a-fca4-45d4-8bd9-66f157a1d51f";
|
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@nix" ];
|
|
|
|
};
|
|
|
|
|
|
|
|
fileSystems."/var/log" = {
|
|
|
|
device = "/dev/disk/by-uuid/5151f79a-fca4-45d4-8bd9-66f157a1d51f";
|
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@log" ];
|
|
|
|
};
|
|
|
|
|
2023-07-23 01:02:21 +02:00
|
|
|
fileSystems."/storage/bunker" = my.homelab.nfsServers.tank.bunker;
|
2023-06-08 21:38:44 +02:00
|
|
|
|
|
|
|
networking = my.homelab.networking // {
|
|
|
|
interfaces.eno1 = my.machines.zero.eno1 // { wakeOnLan.enable = true; };
|
|
|
|
};
|
|
|
|
|
|
|
|
home-manager.users.christoph = {
|
|
|
|
my.emails.personal.enable = true;
|
|
|
|
|
|
|
|
wayland.windowManager.sway.config = let
|
|
|
|
inherit (my.machines.zero) displays;
|
|
|
|
# Assigns five workspaces, starting at `base`, to output `output`.
|
|
|
|
makeWorkspaceOutputAssignList = base: output:
|
|
|
|
builtins.genList (x: {
|
|
|
|
inherit output;
|
|
|
|
workspace = toString (base + x);
|
|
|
|
}) 5;
|
|
|
|
in {
|
|
|
|
workspaceOutputAssign =
|
|
|
|
(makeWorkspaceOutputAssignList 1 (builtins.elemAt displays 0))
|
|
|
|
++ (makeWorkspaceOutputAssignList 6 (builtins.elemAt displays 1));
|
|
|
|
|
|
|
|
assigns = {
|
|
|
|
"6" = [{ app_id = "firefox"; }];
|
|
|
|
"7" = [{ class = "Spotify"; }];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|