Mac OS X,  Mac Security,  Mass Deployment

Mac OS X: User Templates

New users on a Mac have a certain set of default settings that are copied into their user profiles the first time they log in from the contents of the /System/Library/User Template/English.lproj directory.  You can drop files into this directory or edit files that are already there that will then be copied into new accounts when they’re created, allowing you to customize the look and feel, default documents, fonts and other aspects of user accounts without having to do so each time a new user is created or logged into a system.  

This can be incredibly useful for scenarios where you are not using network accounts or mobile accounts and you have a number of different people logging into computers and you want to provide specific settings.  It goes without saying that many policies could be managed through local computer policies using mcx.  However, this is not always going to cover settings you want to use and using templates is easier if you won’t be limiting users from changing settings.

For example, let’s say that you want to provide all users with a default, stock set of Fonts.  If you go to the /System/Library/User Template/English.lproj/Library/Fonts directory then you can simply copy fonts into this folder and they will be provided to users when they log in.  Once they have the fonts in the home directory they will then be able to remove them, but will not otherwise be stuck with them.  The same would be true for any items stored in the home directory, including Microsoft Office preferences.

Another aspect of using user templates is to perform scripts the first time a user logs in.  For example, if you have a Microsoft Exchange environment, you can have Entourage automatically setup a user account the first time they log in by having a self-destructing LaunchAgent in the users home folder (~/Library/LaunchAgents).  This would therefore result in creating LaunchAgents, a script and the agent itself in the User Template, but if you have a large number of users it would save a lot of time in setup.  

Of course, if you’re using Open Directory, Active Directory or some other directory service there are better ways to go about accomplishing much of what you can do with user templates; however it makes a great tool to keep in your bat-belt for when you need it.