Add print server for label printer to have it easily usable via SSH

Add and configure a print server for the Brother P-touch QL 500 label
printer, so that it can be easily used via SSH.

Do the following to make that work:
- Configure the print server host.
- Package printer-driver-ptouch to have a working driver for the label
  printer.
- Configure CUPS.
- Add a script "forcecommand-lpr-wrapper", which works together with the
  ForceCommand sshd_config option and wraps lpr to provide an easy
  interface to use the Brother QL 500 label printer via SSH.
- Add a print user and configure SSH to have the
  "forcecommand-lpr-wrapper" script accessible without a password using
  the print user via SSH.
This commit is contained in:
June 2024-04-14 18:46:51 +02:00
commit c97f169b77
Signed by: june
SSH key fingerprint: SHA256:o9EAq4Y9N9K0pBQeBTqhSDrND5E7oB+60ZNx0U1yPe0
7 changed files with 248 additions and 0 deletions

View file

@ -0,0 +1,23 @@
{ ... }:
{
networking = {
interfaces.net0 = {
ipv4.addresses = [
{
address = "10.31.208.13";
prefixLength = 25;
}
];
};
defaultGateway = "10.31.208.1";
nameservers = [
"10.31.208.1"
];
};
systemd.network.links."10-net0" = {
matchConfig.MACAddress = "BC:24:11:F2:CF:8F";
linkConfig.Name = "net0";
};
}