about summary refs log tree commit diff stats
path: root/system
diff options
context:
space:
mode:
Diffstat (limited to 'system')
-rw-r--r--system/services/printing/default.nix28
1 files changed, 18 insertions, 10 deletions
diff --git a/system/services/printing/default.nix b/system/services/printing/default.nix
index 2e3ef2d2..50f94bcb 100644
--- a/system/services/printing/default.nix
+++ b/system/services/printing/default.nix
@@ -1,9 +1,5 @@
 # vim: ts=2
-{
-  config,
-  pkgs,
-  ...
-}: {
+{pkgs, ...}: {
   services.avahi = {
     enable = true;
     nssmdns = true;
@@ -11,14 +7,26 @@
   };
   services.printing = {
     enable = true;
-    webInterface = false; # don't enable the webinterface
+    webInterface = false;
     drivers = with pkgs; [
       gutenprint
     ];
   };
-  hardware.sane = {
-    # TODO this properly won't work like this
-    enable = true;
-    extraBackends = [pkgs.sane-airscan];
+  hardware = {
+    sane = {
+      # TODO this won't work like this
+      enable = true;
+      extraBackends = [pkgs.sane-airscan];
+    };
+    printers = {
+      ensurePrinters = [
+        {
+          name = "Brother";
+          model = "everywhere";
+          deviceUri = "dnssd://Brother%20DCP-9022CDW._ipp._tcp.local/?uuid=e3248000-80ce-11db-8000-30055c773bcf";
+        }
+      ];
+      ensureDefaultPrinter = "Brother";
+    };
   };
 }