In our company I have to install the Follow Me printers for all Macs via Jamf. I already created a policy for the printer, now I should know how to create the printer via a script at the user. I know that it works with lpadmin but it is not well described on the internet. It should automatically install the Printer with the settings in the Picture. Could someone provide me with a Script or a idea?
lpadmin is the way to go for FollowMePrint, as needed authentication parameters cannot often be forced in GUI settings in my experience.
The below command is very useful to lookup lpadmin available settings for an installed printer to devise the right combination for your needs.
lpoptions -p printername -l
Some example fairly universal options available:
force user name based authentication (that was necessary for followmeprint to work in our setup): auth-info-*required=username,password
disable sharing: printer-is-shared=false
enable duplex functions: OptDuplex=True*
Example below creates a printer called "FolowMePrint" using a generic driver, requiring authentication (to be passed to FMP), disabling sharing, and enabling duplex function.
lpadmin -p FollowMePrint -E -v smb://followmeprint/address -P /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/PrintCore.framework/Resources/Generic.ppd -o auth-info-required=username,password -o printer-is-shared=false -o APOptionalDuplexer=True
Path to the driver, can be substituted with a path to a specific driver. I would be very careful with using any printers relying on printer drivers, as they are due to become deprecated in future iterations of MacOS.
As I understand it print on a Mac will always be Postscript by default and the PPD file only specifies additional hardware information about the printer like trays, duplex and so on. Please correct me if I'm wrong.
I recently installed FollowMe print using a Konica Minolta printer and I downloaded the driver package installer from the official site, ran the installer which gave me this file
which I then used in a postinstall package with the following script for a policy i Self Service:
/usr/bin/stat -f%Su /dev/console
lpadmin -p FollowMePrint -D "FollowMe Print" -E -v lpd://$currentUser@nameofyourprintserver/secure -P /Library/Printers/PPDs/Contents/Resources/KONICAMINOLTAC3350iS.gz -o printer-is-shared=false
When installed the printer is correctly identified as using Postscript:
"KONICA MINOLTA C3350i PS"
I also had to get this working in our environment.
Not sure if it works the same for you at your site, but for us it authenticates through our local AD.
First I had to get the company that runs the FMP software for us to extract the PPD file from their software, per Apple engineers. I was then able to create the printer in Jamf management (attached screenshot).
My next challenge was when enrolling my new machines. I had to exclude our Bind to AD config from the Pre-stage, so I could run a script that will change the machine names to the serial number (just my preference) after enrollment. Once ran and the names change, I drop them all in my static groups in Jamf, they bind to AD with the new machine name. I am then able to log in our AD users and it will create a mobile account that lets them use the FMP.
Any other way I tried adding the printers with FMP, the jobs would not show in the queue since the server didn't know what to do with the requests without the proper PPD file and being an AD account.
Again, not sure if this applies at all to your site, but this was my first dealing with Jamf and managing Macs in enterprise, so it presented quite the challenge for me. Hope any of this helps!