refactored xen_guest.nix

This commit is contained in:
Dennis Frieberg 2023-09-24 02:04:39 +02:00
parent 72c98986a0
commit bc8b37f38d
Signed by: nerf
GPG key ID: 1EC6F5573876CC80
4 changed files with 16 additions and 14 deletions

View file

@ -1,8 +0,0 @@
{
imports = [ ];
boot.loader.grub = {
device = "nodev";
enable = true;
};
}

View file

@ -5,7 +5,7 @@ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
(import ./mail.nix flake-inputs) (import ./mail.nix flake-inputs)
../../roles ../../roles
./boot.nix ../../roles/xen_guest.nix
./network.nix ./network.nix
]; ];

View file

@ -1,11 +1,6 @@
{config, lib, pkgs, modulesPath, ...}: { {config, lib, pkgs, modulesPath, ...}: {
imports = [ ]; imports = [ ];
boot.initrd.availableKernelModules =
[ "ata_piix" "sr_mod" "xen_blkfront" ];
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-uuid/a72da670-f631-49b1-bcb3-6d378cc1f2d0"; device = "/dev/disk/by-uuid/a72da670-f631-49b1-bcb3-6d378cc1f2d0";
fsType = "ext4"; fsType = "ext4";

15
nixos/roles/xen_guest.nix Normal file
View file

@ -0,0 +1,15 @@
{...}: {
imports = [ ];
boot = {
loader.grub = {
device = "nodev";
enable = true;
};
initrd = {
availableKernelModules = [ "ata_piix" "sr_mod" "xen_blkfront" ];
kernelModules = [ ];
};
extraModulePackages = [ ];
};
}