CUPS in docker - not detecting printer connected after container is started

dragonn

Cadet
Joined
Sep 12, 2021
Messages
2
Hi!
I recently moved TrueNAS SCALE and absolute love it! I have quite huge experience with Linux but didn't really like BSD.
I already setup like 5 containers doing different tasks and it works really nice.
I am only having an issue with my CUPS container, it works, prints but one of the connected printers has a stupid "auto turn off option".
After it turns off CUPS doesn't detected the printer back unless I stop the container and start again.
The containers runs in "Privileged Mode" so it sees the whole /dev.
I also tried binding "/var/run/udev" and "/var/run/dbus" but that didn't change nothing, always get's stuck at ""Waiting for printer to become available."" after the printer turns off and I turn it back on before printing.
What is strange lsusb does show the printer back in the container, udevadm monitor also shows the right events. But CUPS doesn't see it and it isn't visible in lpadmin.
I also tried blacklisting usblp since CUPS doesn't need it and that didn't change nothing (but printing still works without it).
At this point I run out of ideas. Will be were grateful for any help!
Thanks!
 

dragonn

Cadet
Joined
Sep 12, 2021
Messages
2
hi,
try to add"--device /dev/bus"
I know what you are talking about but how can I do that in TrueNAS from the GUI? Or editing some files. I have no idea how to do that.
Is that "Configure Container Args"? I was thinking those are arguments for the Container CMD?
 

justin82

Cadet
Joined
Feb 16, 2021
Messages
6
I using the docker command, not in chart. so I have no idea for GUI.
attached the example what I run.

Code:
docker run -d \
       --name=cupsd \
       --restart=unless-stopped \
       -p 631:631 \
       -v /var/run/dbus:/var/run/dbus \
       --device /dev/bus \
olbat/cupsd
 
Top