feat: big refactor

This commit is contained in:
Jacob Bachmann 2024-09-07 15:10:22 +02:00
parent 2c09c21833
commit ebedec9768
No known key found for this signature in database
GPG key ID: 7753026D577922A6
159 changed files with 1927 additions and 2222 deletions

38
modules/core/printing.nix Normal file
View file

@ -0,0 +1,38 @@
{
pkgs,
lib,
config,
...
}:
{
options.bchmnn = {
printing = {
enable = lib.mkEnableOption "printing";
};
};
config = lib.mkIf config.bchmnn.printing.enable {
services.printing = {
enable = true;
drivers = [ pkgs.mfcl3750cdwcupswrapper ];
};
services.avahi = {
enable = true;
nssmdns4 = true;
openFirewall = true;
};
hardware.printers = {
ensurePrinters = [
{
name = "Brother-MFC-L3750CDW-series";
location = "Home";
deviceUri = "dnssd://Brother%20MFC-L3750CDW%20series._ipp._tcp.local/?uuid=e3248000-80ce-11db-8000-b4220094c09b";
model = "brother_mfcl3750cdw_printer_en.ppd";
}
];
ensureDefaultPrinter = "Brother-MFC-L3750CDW-series";
};
};
}