nixos-config/machines/vueko/hardware-configuration.nix

55 lines
1.3 KiB
Nix

# SPDX-FileCopyrightText: 2021-2024 Simon Bruder <simon@sbruder.de>
#
# SPDX-License-Identifier: AGPL-3.0-or-later
{ config, lib, pkgs, modulesPath, ... }:
{
imports = [
(modulesPath + "/profiles/qemu-guest.nix")
];
sbruder.machine.isVm = true;
boot = {
kernelParams = [ "ip=dhcp" ];
initrd = {
availableKernelModules = [ "aes_neon_bs" "aes_neon_blk" "xhci_pci" "virtio_pci" "usbhid" "sr_mod" ];
network.enable = true; # remote unlocking
luks.devices."root".device = "/dev/disk/by-uuid/98d0762c-4a87-45e5-8e99-5147f929fa1b";
};
loader = {
grub.enable = false;
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
};
fileSystems = {
"/" = {
device = "/dev/disk/by-uuid/330f15f5-84f9-446a-a77d-c788fd4b898b";
fsType = "btrfs";
options = [ "compress=zstd" ];
};
"/boot" = {
device = "/dev/disk/by-uuid/7F59-E838";
fsType = "vfat";
};
};
networking.useDHCP = false;
networking.usePredictableInterfaceNames = false;
systemd.network = {
enable = true;
networks = {
eth0 = {
name = "eth0";
DHCP = "yes";
domains = [ "sbruder.de" ];
address = [ "2a01:4f8:c012:2f4::1/64" ];
gateway = [ "fe80::1" ];
};
};
};
}