mirror of
https://gitlab.com/Zaney/zaneyos.git
synced 2025-01-22 04:08:36 +01:00
Add all printing support and add vm guest services module
This commit is contained in:
parent
69f449823b
commit
c3280afa7a
@ -16,6 +16,7 @@ in
|
||||
./users.nix
|
||||
../../modules/amd-drivers.nix
|
||||
../../modules/nvidia-drivers.nix
|
||||
../../modules/vm-guest-services.nix
|
||||
];
|
||||
|
||||
# Bootloader.
|
||||
@ -179,6 +180,17 @@ in
|
||||
services.libinput.enable = true;
|
||||
services.openssh.enable = true;
|
||||
services.printing.enable = true;
|
||||
services.avahi = {
|
||||
enable = true;
|
||||
nssmdns4 = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
services.ipp-usb.enable = true;
|
||||
hardware.sane = {
|
||||
enable = true;
|
||||
extraBackends = [ pkgs.sane-airscan ];
|
||||
disabledDefaultBackends = [ "escl" ];
|
||||
};
|
||||
# Enable sound with pipewire.
|
||||
sound.enable = true;
|
||||
hardware.pulseaudio.enable = false;
|
||||
@ -239,6 +251,7 @@ in
|
||||
# Extra Module Options
|
||||
drivers.amdgpu.enable = true;
|
||||
drivers.nvidia.enable = false;
|
||||
vm.guest-services.enable = false;
|
||||
|
||||
# Open ports in the firewall.
|
||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||
|
@ -19,6 +19,8 @@ in
|
||||
"networkmanager"
|
||||
"wheel"
|
||||
"libvirtd"
|
||||
"scanner"
|
||||
"lp"
|
||||
];
|
||||
shell = pkgs.bash;
|
||||
ignoreShellProgramCheck = true;
|
||||
|
21
modules/vm-guest-services.nix
Normal file
21
modules/vm-guest-services.nix
Normal file
@ -0,0 +1,21 @@
|
||||
{
|
||||
lib,
|
||||
pkgs,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
let
|
||||
cfg = config.vm.guest-services;
|
||||
in
|
||||
{
|
||||
options.vm.guest-services = {
|
||||
enable = mkEnableOption "Enable Virtual Machine Guest Services";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.qemuGuest.enable = true;
|
||||
services.spice-vdagentd.enable = true;
|
||||
services.spice-webdavd.enable = true;
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue
Block a user