[cups] How to call a script when a job arrives
Brian Potkin
claremont102 at gmail.com
Fri Apr 5 02:47:52 PDT 2019
On Fri 05 Apr 2019 at 10:30:18 +0200, Daniel Spannbauer wrote:
> Am 05.04.2019 um 10:11 schrieb Marc Haber:
> > Hi,
> >
> > I have a network printer that can be turned on by doing a certain curl
> > call, and would like CUPS to turn the printer on automatically when a
> > print job for this printer arrives.
> >
> > Must I do this in a filter or is there a more elegant place for this?
> > How and where would I specify a filter that is used for all jobs for a
> > certain printer?
> >
> > Greetings
> > Marc
> >
> Hello Marc,
>
>
> I write a script, name it like the printer and put it to the interfaces dir
> (at openSUSE: /etc/cups/interfaces/).
>
> Mine would look like this:
>
> -----------
>
> #!/bin/bash
>
> do_anything_to_wake_the_printer
>
> cat $6
>
> -------------
>
> I think that should work.
Interface scripts have been unsupported by CUPS since v2.2b1. I would
use Tea4CUPs. There is a Debian wiki page.
Regards,
Brian.
More information about the cups
mailing list