I need to add printer output tray which has virtual name how can I add that tray as printer in Ubuntu.
I need to add that printer with shell command not in GUI.
I need to add printer output tray which has virtual name how can I add that tray as printer in Ubuntu.
I need to add that printer with shell command not in GUI.
I found the answer
I need to add new printer as shell script which can be part of my charm config.
With lpadmin (adding new network /shared printer) there is an option part -o [options]
All options are printer specific and all defined in printer's PPD
Install printer with correct PPD
Look at all "options" with lpoptions -p [Printer Name -l]; it displays all printer's features as options and finds Output Tray or Output Bin
In my case it was "OutputBin=" however in one of my printers the tray or bin numbers were Bin1,Bin2, ... and the other one was MailBoxBin1, MailBoxBin2,..
So the correct command is:
lpadmin -p [printer local name] -v smb://domain/user:pass@printer_server_IP/Printer_shared_name [ or socket://printer_IP:port/ ] virologic/apprunner:Y0g1Bear@10.196.1.250/ITPrinterBW -E -P [printer PPD file]-o OutputBin=Bin1