Fixing up VM setup

This commit is contained in:
Bryan Ramos 2025-02-18 10:12:48 -05:00
parent 608100b359
commit e1e8c16bcd
Signed by: bryan
GPG key ID: 6ABDCD144D6643C8
3 changed files with 210 additions and 2 deletions

View file

@ -1,7 +1,8 @@
{ pkgs, lib, config, ... }:
with lib;
{ system.stateVersion = "23.11";
{
system.stateVersion = "23.11";
users.users = {
${config.user.name} = {
@ -123,4 +124,19 @@ with lib;
};
};
};
} // attrsets.optionalAttrs (
config.virtualisation ? libvirt && config.virtualisation.libvirt.enable ||
config.virtualisation.libvirtd.enable)
{
systemd.tmpfiles.rules = [
"d /home/VMs 0755 root root"
];
fileSystems = {
"/var/lib/libvirt/images" = {
device = "/home/VMs";
fstype = "none";
options = [ "bind" ];
};
};
}