nix-config/packages/vm.nix
2024-06-05 12:36:51 -05:00

63 lines
1.4 KiB
Nix

{
inputs,
outputs,
configLib,
...
}:
inputs.nixos-generators.nixosGenerate {
system = "x86_64-linux";
specialArgs = {inherit inputs outputs configLib;};
format = "qcow";
modules = [
inputs.home-manager.nixosModules.home-manager
../configs/nixos/sshd.nix
../configs/nixos/common.nix
../roles/nixos/vm.nix
({
config,
pkgs,
configLib,
modulesPath,
...
}: {
imports = [(modulesPath + "/profiles/qemu-guest.nix")];
host.user = "gabe";
users.users.root.password="nixos";
programs.zsh.enable = true;
environment.shells = with pkgs; [zsh];
users.users.${config.host.user} = {
isNormalUser = true;
description = "Gabe Venberg";
shell = pkgs.zsh;
extraGroups = ["wheel"];
password="nixos";
};
home-manager.users.${config.host.user} = {
inputs,
osConfig,
...
}: {
host = osConfig.host;
user = {
git = {
profile = {
name = "Gabe Venberg";
email = "gabevenberg@gmail.com";
};
workProfile.enable = false;
};
};
imports = [
../roles/home-manager/minimal-terminal.nix
../configs/home-manager/common.nix
inputs.nixvim.homeManagerModules.nixvim
];
};
system.stateVersion = "24.05";
})
];
}