Migrate gaming to flakes

This commit is contained in:
Vili Sinervä 2025-06-05 00:41:01 +03:00
parent ab643fb514
commit 8d9f10347e
Signed by: Vili Sinervä
SSH key fingerprint: SHA256:FladqYjaE4scJY3Hi+gnShZ6ygnTJgixy0I6BAoHyos
2 changed files with 47 additions and 3 deletions

View file

@ -1,16 +1,15 @@
{ lib, ... }:
{
networking.hostName = "gaming";
imports = [
../../shared/base.nix
../../shared/hardware/nvidia.nix
../../shared/hardware/vm.nix
../../personal/desktop.nix
../../personal/programs/i3.nix
../../servers/gaming-server.nix
];
users.users.vili.hashedPasswordFile = lib.mkForce null;
services.qemuGuest.enable = true;
}

45
hosts/gaming/state.nix Normal file
View file

@ -0,0 +1,45 @@
{ lib, modulesPath, ... }:
{
system.stateVersion = "24.11";
imports = [
(modulesPath + "/profiles/qemu-guest.nix")
];
boot.initrd.availableKernelModules = [
"uhci_hcd"
"ehci_pci"
"ahci"
"xhci_pci"
"virtio_pci"
"virtio_scsi"
"sd_mod"
"sr_mod"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
fileSystems."/" = {
device = "/dev/disk/by-uuid/22c7a7ae-cedc-43db-b4f1-d591466d8f60";
fsType = "ext4";
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/1C79-66D7";
fsType = "vfat";
options = [
"fmask=0077"
"dmask=0077"
];
};
fileSystems."/mnt/data" = {
device = "/dev/disk/by-uuid/dec871b2-5727-486c-978a-8bb2279bd2b8";
fsType = "ext4";
};
networking.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
}