Added working example

This commit is contained in:
2026-03-21 20:01:50 +00:00
parent 73284fa1da
commit 8ab9d28526
25 changed files with 1493 additions and 0 deletions
@@ -0,0 +1,24 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/profiles/qemu-guest.nix")
];
boot.initrd.availableKernelModules = [ "ahci" "xhci_pci" "virtio_pci" "sr_mod" "virtio_blk" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/cc3cc0f4-b589-454b-9d73-2707f25952c0";
fsType = "ext4";
};
swapDevices = [ ];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
}
@@ -0,0 +1,48 @@
# hosts/nixovm/nixovm.nix
{ inputs, config, ... }:
{
flake.nixosConfigurations."nixovm" = inputs.nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules =
[
inputs.home-manager.nixosModules.home-manager
inputs.stylix.nixosModules.stylix
] ++
(builtins.attrValues config.flake.nixosModules) ++
[
./hardware-configuration.nix
({ ... }: {
networking.hostName = "nixovm";
system.stateVersion = "25.11";
swapDevices = [ {
device = "/var/lib/swapfile";
size = 4096; # 4 GB
} ];
boot.loader.grub.enable = true;
boot.loader.grub.device = "/dev/vda";
boot.loader.grub.useOSProber = true;
# Enable various user-defined modules
mySystem = {
# Turn on the core system
system.core.enable = true;
# Enable Apps
apps.foot.enable = true;
apps.yazi.enable = true;
# Define Environment
desktop.hyprland.enable = true;
desktop.noctalia.enable = true;
desktop.stylix.enable = true;
};
})
];
};
}