os/modules/printing/default.nix
Benjamin Bädorf 7be9e41657
All checks were successful
continuous-integration/drone/push Build is passing
fix: add support for QL-800
2023-09-12 20:10:55 +02:00

34 lines
774 B
Nix

{
lib,
config,
pkgs,
...
}:
with lib; let
psCfg = config.pub-solar;
cfg = config.pub-solar.printing;
in {
options.pub-solar.printing = {
enable = mkEnableOption "CUPSSSss";
};
config = mkIf cfg.enable {
services.avahi.enable = true;
services.avahi.nssmdns = true;
services.avahi.publish.enable = true;
services.avahi.publish.userServices = true;
services.printing.enable = true;
services.printing.browsing = true;
services.printing.listenAddresses = ["localhost:631"];
services.printing.allowFrom = ["all"];
services.printing.defaultShared = false;
services.printing.drivers = [
pkgs.gutenprint
];
hardware.sane = {
enable = true;
extraBackends = [pkgs.hplipWithPlugin];
};
};
}