Viewing entries tagged
profile

Automate the Setup of Microsoft Exchange Accounts on OS X

2 Comments

Automate the Setup of Microsoft Exchange Accounts on OS X

I have been recently looking for the best way to automate the setup of Exchange accounts (specifically Office 365 hosted) on shared Macs. William Smith has created an impressive Exchange Setup AppleScript, perfect for Microsoft Outlook users.

I also wanted to automate the setup of Exchange accounts for Apple’s native OS X apps (Mail, Contacts, Calendars, Reminders and Notes). Normally this would be done with a Mobile Device Management (MDM) solution, pushing out user personalised configuration profiles. But for those situations where a MDM isn’t feasible (possibly due to budget, resources, policy, etc.) or simply overkill this post should help you out. 

To make life easier for those without a MDM I have put together a bash script to automate the setup of Exchange accounts on OS X.

 

How it works

The script locally generates and installs a user configuration profile (.mobileconfig file). To avoid the account being added as offline the user is also prompted for their Exchange account password.

Usage

I have tested this script on OS X El Capitan (10.11) with multiple Office 365 Exchange accounts.

  1. Install Joseph Chilcote's Outset script.
  2. Download the addexchangeaccount.sh script and customise the required DOMAIN and EXCHANGE_HOST values.
  3. Then copy the customised script into /usr/local/outset/login-once/ and remember to make it executable.

That's it! The first time a user logs in they are prompted to enter their Exchange account password and then the script does the rest.

2 Comments

Dock Master - A Superior Profile Maker for Managing the Dock

364 Comments

Dock Master - A Superior Profile Maker for Managing the Dock

Recently I have been actively looking into the best solution for setting a custom dock on multiple machines.

Apple’s Profile Manager allows the creation of configuration profiles with dock settings. However, the functionality has some frustrating limitations:

  • There is no control over the order in which applications are displayed in the dock.

  • You can only add applications to Profile Manager if they are installed (note: can be dummy .app files) on the OS X Server host itself.

  • No home directory relative path support, therefore you cannot simply add a user’s Downloads folder to the dock.

The Search for Something Better

I tried Kyle Crawford’s dockutil command line tool and found it worked well for changing the dock of existing local accounts, but required scripting (LaunchAgent) to apply to newly created accounts.

I also had temperamental success in directly editing:
/System/Library/CoreServices/Dock.app/Contents/Resources/en.lproj/default.plist
/System/Library/CoreServices/Dock.app/Contents/Resources/com.apple.dockfixup.plist

After that I tried using Tim Sutton’s mcxToProfile script to convert ~/Library/Preferences/com.apple.dock.plist into a profile. Unfortunately home directory relative folders were broken using this technique.

Get To The Good Stuff

Over the past week I started working on a tool to make generating dock configuration profiles easy and include all the features missing from other tools.

The advantages of my solution (Dock Master) include:

  • Support for home directory relative paths (e.g. ~/Downloads).

  • The ability to include applications that are not installed.

  • Inclusion of network shares and website links with custom labels.

  • The ability to set folder attributes (sort by, display as and view content as).

Dock Master is an intuitive way to customise and generate dock profiles. To help you get started I have included some sample data commonly featured in education docks and an example of a directory, share and website that can be edited/removed as required. Once all the desired alterations have been made the profile is ready to be downloaded and distributed.

Removable Dock Items

A few people have contacted me asking if there’s way to deploy a custom dock with removable items. Unfortunately, configuration profiles do not allow for this. Dock Master now works around this limitation by creating a dock preference file that is added to the User Template (new user accounts) and optionally replaces the dock plist in existing user accounts.

Below you will notice a lock icon next to each dock item, unlocked items are removable by the end user. If one or more dock items are unlocked, Dock Master generates a tar file (compressed archive) instead of a configuration profile.

Once the tar file (archive) is extracted you will have a folder containing a ‘makepackage.command’ script. To build your custom package, simply right click the script and select Open.

The resulting package can be deployed just like any other package (e.g. Apple Remote Desktop, AutoDMG, DeployStudio, Munki, etc).

Name


Applications

Please provide the full path to the application (.app file).

Others (Folders/Shares/URLs/Weblocs)


Additional Options

Profile description:
Profile scope:
Prevent users from permanently modifying dock contents.
Merge with user's existing/default dock.
Add user's network home folder.
Maximum icon size (1-256):
Enable magnification. | Maximum magnification size (1-256):
Dock position:
Minimize windows using:
Apps animate (bounce) on open.
Automatically hide and show the dock.
Show indicators for open applications.
Minimise windows into app icon.
Create package instead of profile. | Package applies to existing users. | Package version:
Target macOS:

Do You Like Dock Master?

If you appreciate my work on Dock Master please consider making a donation. Dock Master has been a hobby project, I never developed it planning to make money (although my partner thinks I should) and I felt it was my way of contributing to the Mac Admin community. Donations help offset server hosting costs and access to resources.

 

FAQ

I have downloaded my fancy dock profile/package, how do I push it out to all my users?
There are several ways to distribute profiles and packages, I recommend simply importing them straight into Munki.

What happens if I want to change a Dock Master profile already installed on my clients?
Dock Master profiles use the dock name as the profile identifier, therefore if you use the same name the new dock profile will overwrite the old. Dock Master packages simply overwrite any prior installed Dock Master package.

Can I reorder dock items?
Yes, simply click and drag the ≡ sign to change the position of a dock item.

I still don’t get it, why would I use this?
It's free!!!

In education environments younger students find it difficult to find an application in Finder or the Launchpad, therefore having applications sitting in the dock allows students to independently access the applications they need.

This tool allows advanced customisation and quick generation of dock profiles that can be applied to different device groups (e.g. Art, Music, Junior School Macs).

And lastly because it's awesome!

Where can I find the source code?

I was surprised with the demand for Dock Master. Since its release I have rewritten Dock Master (originally PHP) into a native OS X Swift command-line tool for offline use. You can find the source code on GitHub here.

364 Comments