fix: install cups on non-sharing printing devices

This commit is contained in:
Benjamin Bädorf 2023-10-10 12:23:05 +02:00
parent ece9705f67
commit f3d9915d2f
No known key found for this signature in database
GPG key ID: 4406E80E13CD656C
4 changed files with 21 additions and 1 deletions

View file

@ -16,6 +16,7 @@
self.nixosModules.graphical
self.nixosModules.nextcloud
self.nixosModules.office
self.nixosModules.printing
self.nixosModules.uhk
];
};
@ -35,6 +36,7 @@
self.nixosModules.graphical
self.nixosModules.nextcloud
self.nixosModules.office
self.nixosModules.printing
self.nixosModules.uhk
self.nixosModules.virtualisation
];

View file

@ -4,6 +4,7 @@
./configuration.nix
./networking.nix
./printing.nix
./unbound.nix
./dhcpd.nix
./wake-droppie.nix

17
hosts/pie/printing.nix Normal file
View file

@ -0,0 +1,17 @@
{
flake,
config,
pkgs,
lib,
...
}: {
services.caddy = {
enable = true;
extraConfig = ''
cups.b12f.io:80 {
request_header Host localhost:631
reverse_proxy unix//run/cups/cups.sock
}
'';
};
}

View file

@ -31,7 +31,7 @@
services.caddy = {
enable = true;
extraConfig = ''
cups.b12f.io:80 {
cups.local {
request_header Host localhost:631
reverse_proxy unix//run/cups/cups.sock
}