Getting Started Need some help with User Profile/Lab use

JTP
New Contributor II

I need to be pointed in the right direction for getting a bunch of macs configured for lab use. I was a long time holdout of Deploy Studio.

Chiefly, I have several software titles that call for prefs in the user profile. Before JAMF I would just edit/add the default user profile and it worked great. Now with Mojave it looks like I can't edit this and the topics I've found on here appear to be dated with regards to configuration profiles. Now I'm reading that login hooks are getting phased out by apple. The onboard trainer said that everything should be done with policy. The Biggest app in question is Font Explorer X, the local profile prefs point it to our license server and the extra fonts on the system. I would like to have this configured for our 1000 users as they log in.

I'm lost, I'm noob and I need a shaman to guide me. If I need to write a script, could you provide or point to an example.

4 REPLIES 4

JTP
New Contributor II

Bueller? Bueller?

Chris_Hafner
Valued Contributor II

I'll jump on here later and see if I can help more. Weird that this wasn't picked up on earlier. Anyways, what's your level of training/farmiliarity with JAMFPro?

PaulHazelden
Valued Contributor

Login hooks are replaced by LaunchAgents and LaunchDaemons. They are pretty easy to use, Agents run as the logging in user, and Daemons run as root. They can be used to launch Apps, or scripts.

The user template is awkward to modify, but it is possible. A lot of it is protected by SIP, but you are saying you want to add a plist to the preferences to set up an app. If you are adding a plist, in my testing this is possible in Mojave. If you are wanting to change an existing plist, you might run into problems. I have a few Apps, NoMAD is one, for which I need the Prefs already set up as the user logs in. I use the defaults write command to create and populate the plist in the user templates. This is all done by a first run script, that I send to all of my Macs as they are enrolled after erasing.
The first run script also installs a bunch of Agents and Daemons for me. One of the Agents is a login script. If your app is not requiring the prefs to be set up as the user logs in, but can be set up prior to the launch of the App, then you can script the preferences in a login Agent.

If you hunt around on here there are loads of first run scripts and login scripts for you to work with, it will all depend on what you are requiring to do.
For example, to setup your prefs for Font Explorer, you are going to want to do something like this...

defaults write com.plist.for.fontexplorer ServerSettings myServerName

Please note, the plist name is wrong and the ServerSettings is wrong. You can find out the correct info by opening a configured version. Again there are various examples of the defaults command available.
If this gets run as the logging in user by a LaunchAgent it will be put in the users own Library Preferences, and will be available to them.

dsavageED
Contributor III

If it is just preferences (plist files in ~/Library/Preferences) then this can be done with a custom user/computer level configuration profile. Custom settings allow you to upload a plist file, this should be cleaned down to only the config you need as it will merge with the users preference. For example we use NoMAD and push the pref in this way by uploading this custom plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>ADDomain</key>
    <string>ed.ac.uk</string>
    <key>ChangePasswordType</key>
    <string>None</string>
    <key>DontMatchKerbPrefs</key>
    <false/>
    <key>GetHelpOptions</key>
    <string>http://www.ed.ac.uk/information-services/help-consultancy/it-help</string>
    <key>GetHelpType</key>
    <string>URL</string>
    <key>HidePrefs</key>
    <true/>
    <key>HideQuit</key>
    <true/>
    <key>KerberosRealm</key>
    <string>ED.AC.UK</string>
    <key>LocalPasswordSync</key>
    <true/>
    <key>LocalPasswordSyncOnMatchOnly</key>
    <true/>
    <key>MenuGetHelp</key>
    <string>Help and Support</string>
    <key>MenuGetSoftware</key>
    <string>Self Service</string>
    <key>MenuHomeDirectory</key>
    <string>My Network Home</string>
    <key>MenuRenewTickets</key>
    <string>Sign In</string>
    <key>RenewTickets</key>
    <true/>
    <key>SecondsToRenew</key>
    <integer>7200</integer>
    <key>ShowHome</key>
    <true/>
    <key>UserAging</key>
    <false/>
    <key>UseKeychain</key>
    <true/>
    <key>Verbose</key>
    <false/>
</dict>
</plist>