[cups.general] Passing variables from Samba to CUPS ?

Kurt Pfeifle kpfeifle at danka.de
Sat May 22 05:11:44 PDT 2004


Pavel Duda wrote:
> Is there some easy way how to pass variables ( client vars %m %I,
> user vars %u %H etc. ) from Samba to CUPS ? I'd like to use these
> for job names.
>

If you set the (service level) parameter

  printing = bsd

and an appropriate "print command" containing your variables, it
should work. The print command "lp" takes a "-t" parameter for the
job title, "lpr" takes either of "-C", "-J" or "-T". (NOTE, that a
bug in versions prior to Samba 3.0.3 prevented the customzied print
commands for CUPS to work properly).

Also, you could play with the new smb.conf parameter "cups options"
introduced with Samba-3.0.3. It only works if you have

  printing = cups

See this example:

  cups options = raw,job-sheets=secret,standard,job-hold-until=indefinite

I could imagine that it would also use variables like %m, %u. You
could try this:

  cups options = job-title=%m-%u

I am not sure if it works and can't test it right now. But it is
worth trying. Please let this list know about the results. If it
doesn't work, it is worth while talking to Gerry Carter from the
Samba Team to get it in.

>   Thanks
>   - Pavel
>

Cheers,
Kurt




More information about the cups mailing list