dotfiles/nixos/tests/hel/qemu-vm.nix
magic_rb 0e7389fcbd
More network test work
Signed-off-by: magic_rb <magic_rb@redalder.org>
2024-08-14 15:59:24 +02:00

30 lines
674 B
Nix

{
inputs',
lib,
...
}: let
inherit
(lib)
mkDefault
mkImageMediaOverride
;
in {
imports = [
"${inputs'.nixpkgs-stable}/nixos/modules/virtualisation/qemu-vm.nix"
];
services.getty.autologinUser = "nixos";
users.users.nixos = {
isNormalUser = true;
extraGroups = ["wheel" "video"];
# Allow the graphical user to login without password
initialHashedPassword = "";
};
# Allow the user to log in as root without a password.
users.users.root.initialHashedPassword = "";
# Allow passwordless sudo from nixos user
security.sudo = {
enable = mkDefault true;
wheelNeedsPassword = mkImageMediaOverride false;
};
}