framework: Enable QEMU.

main
Joshua Potter 2023-12-11 07:36:33 -07:00
parent 91fdeb5b47
commit 9af5ef490c
2 changed files with 21 additions and 6 deletions

View File

@ -75,10 +75,13 @@
time.timeZone = "America/Denver";
virtualisation.docker.rootless = {
enable = true;
# Sets the `DOCKER_HOST` variable to the rootless Docker instance for normal
# users by default.
setSocketVariable = true;
virtualisation = {
libvirtd.enable = true;
docker.rootless = {
enable = true;
# Sets the `DOCKER_HOST` variable to the rootless Docker instance for normal
# users by default.
setSocketVariable = true;
};
};
}

View File

@ -11,7 +11,14 @@
useUserPackages = true;
users.jrpotter = args@{ pkgs, lib, ... }:
let
base = import ../../users/jrpotter args;
base = import ../../users/jrpotter args // {
dconf.settings = {
"org/virt-manager/virt-manager/connections" = {
autoconnect = ["qemu:///system"];
uris = ["qemu:///system"];
};
};
};
in
lib.attrsets.updateManyAttrsByPath [
{
@ -21,6 +28,7 @@
bitwarden
firefox
gimp
virt-manager
wezterm
zotero
]);
@ -31,11 +39,15 @@
extraSpecialArgs = { inherit system stateVersion; };
};
# virt-manager requires dconf to remember settings.
programs.dconf.enable = true;
users.users.jrpotter = {
isNormalUser = true;
extraGroups = [
"docker"
"networkmanager"
"libvirtd"
"wheel"
];
};