homelab framework module init (everything is a mess)
This commit is contained in:
parent
0347f4d325
commit
bcbcc8b17b
94 changed files with 7289 additions and 436 deletions
43
profiles/proxmox-vm.nix
Normal file
43
profiles/proxmox-vm.nix
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
# profiles/proxmox-vm.nix - Proxmox VM specific profile
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/profiles/qemu-guest.nix")
|
||||
];
|
||||
|
||||
# Proxmox VM specific configuration
|
||||
services.qemuGuest.enable = true;
|
||||
|
||||
# Boot configuration for Proxmox VMs
|
||||
boot = {
|
||||
loader.grub = {
|
||||
enable = true;
|
||||
devices = ["nodev"];
|
||||
};
|
||||
growPartition = true;
|
||||
tmp.cleanOnBoot = true;
|
||||
|
||||
# Proxmox specific kernel modules
|
||||
initrd.availableKernelModules = ["ata_piix" "uhci_hcd" "virtio_pci" "sr_mod" "virtio_blk"];
|
||||
};
|
||||
|
||||
# Standard Proxmox VM filesystem
|
||||
fileSystems."/" = lib.mkDefault {
|
||||
device = "/dev/disk/by-label/nixos";
|
||||
autoResize = true;
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
# Update global config with Proxmox-specific info
|
||||
homelab = {
|
||||
location = lib.mkDefault "proxmox-cluster";
|
||||
tags = lib.mkDefault ["proxmox-vm" "homelab"];
|
||||
};
|
||||
|
||||
# VM-specific optimizations
|
||||
services.fstrim.enable = true;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue