mirror of
https://github.com/hyprwm/hyprland-infra.git
synced 2025-05-12 21:30:36 +01:00
35 lines
700 B
Nix
35 lines
700 B
Nix
{
|
|
config,
|
|
modulesPath,
|
|
...
|
|
}: {
|
|
imports = [(modulesPath + "/virtualisation/qemu-vm.nix")];
|
|
|
|
virtualisation = {
|
|
memorySize = 8000;
|
|
diskSize = 200000;
|
|
cores = 8;
|
|
|
|
# fs
|
|
useDefaultFilesystems = false;
|
|
rootDevice = "/dev/disk/by-label/NIXOS_ROOT";
|
|
|
|
fileSystems = {
|
|
"/" = {
|
|
device = "${config.virtualisation.rootDevice}";
|
|
fsType = "xfs";
|
|
};
|
|
};
|
|
|
|
interfaces = {
|
|
vm0.vlan = 1;
|
|
};
|
|
|
|
# mac addr can be anything, especially the last 3 bytes
|
|
# the OUI is specific to QEMU
|
|
qemu.networkingOptions = [
|
|
"-device virtio-net-pci,netdev=user0,mac=52:54:00:00:00:00"
|
|
"-netdev bridge,id=user0,br=br0"
|
|
];
|
|
};
|
|
}
|