Managed Dock and placement of icons

gersteina1
New Contributor III

We're new to JSS and all it's wonderfulness, so if I'm missing something, I hope it's nothing obvious.

We're moving from Apples WorkGroup Server to JSS to manage preferences. I added the Dock items for some of our most commonly managed apps into Admin, and they are in the prefs when I look for them. I can add them, but I can only define as "Add to Beginning" and "Add to End" - so I can define one as the beginning, but the rest seem to go in some semi-random order after that.

Is there a way to manage this better? We're doing this mostly in labs, where we want to present a consistent user experience. I tried to do it with an MCX, but that seems not work nearly as well, which is weird when you consider what a good job the WGS could do.

5 REPLIES 5

tkimpton
Valued Contributor II

https://jamfnation.jamfsoftware.com/discussion.html?id=3668

gersteina1
New Contributor III

While that's helpful, it doesn't really do what I want - allow me to use JSS to replace the WGS. It actually adds yet another thing to the mix... I'll check it out anyway.

mm2270
Legendary Contributor III

You're going to become completely frustrated and angry if you attempt to use the add to dock function of the jamf binary to manage your Dock, at least if you're looking for exact placement. While I'm sure there's some logic to how it works, I gave up on trying to use it that way long ago for the same reasons you've run into. its really only for adding a new icon to a Dock during installs, not for setting up an entire Dock exactly as you would like.

You'd be better off trying one of the following-

- Pre-populating the Dock plist in the User Template OS directory, so any new accounts get a stock configured Dock. Downside of this is it doesn't help with existing accounts. Only new ones going forward.

- Try pushing a full MCX array with your Dock setup to your systems. This sometimes works and sometimes doesn't. It isn't the most reliable way to do it, and can take some experimentation to get it working.

- Use OS X Configuration Profiles to set up the Dock. Downside= only allows for Apple applications, not 3rd party ones. I have no idea why Apple designed it this way. Kind of dumb if you ask me, but that's how it currently works.

- Try out dockutil as mentioned above. Yes, it does add a little complexity, but the app works really well and is extremely well documented by the author, so its easy-peasy to use. Its a tiny binary and is a quick package up and deploy with a policy or via an imaging.workflow.

cbrewer
Valued Contributor II

Managed Preferences in the JSS is what you want for replacing WGM settings. You'll need to spend some time playing around to get it working, but it does the job.

Create a preference with something along the lines of...

<array>
    <dict>
        <key>mcx_typehint</key>
        <integer>1</integer>    
        <key>tile-data</key>
        <dict>
            <key>file-data</key>
            <dict>
                <key>_CFURLString</key>
                <string>/Applications/Safari.app</string>
                <key>_CFURLStringType</key>
                <integer>0</integer>
            </dict>
            <key>file-label</key>
            <string>Safari</string>
        </dict>
        <key>tile-type</key>
        <string>file-tile</string>
    </dict>
    <dict>
        <key>mcx_typehint</key>
        <integer>1</integer>
        <key>tile-data</key>
        <dict>
            <key>file-data</key>
            <dict>
                <key>_CFURLString</key>
                <string>/Applications/Firefox.app</string>
                <key>_CFURLStringType</key>
                <integer>0</integer>
            </dict>
            <key>file-label</key>
            <string>Firefox</string>
        </dict>
        <key>tile-type</key>
        <string>file-tile</string>
    </dict>
</array>

gersteina1
New Contributor III

Thanks @cbrewer - that seems to be doing the trick so far.