{ lib, config, ... }: let cfg = config.services.ntnuPrinting; in { options.services.ntnuPrinting.enable = lib.mkEnableOption "Enable NTNU printing service"; config = lib.mkIf cfg.enable { services.printing.enable = true; services.printing.browsed.enable = true; hardware.printers.ensurePrinters = [ { name = "NTNU-Print"; location = "NTNU"; deviceUri = "https://myprint.ntnu.no/RicohmyPrint/printers/ipp/print"; model = "myPrint_PS.ppd"; ppdOptions = { PageSize = "A4"; }; } ]; }; }