Posted on 05-15-2019 08:57 AM
DockBuilder allows for the building of a user's Dock based on an organization's needs. DockBuilder eliminates the need for a user template which only allows for a static Dock for all users, and template manipulation can cause issues in newer versions of macOS. DockBuilder not only allows for easy creation of a new user's Dock out of the box, but also has the potential to dynamically set up a different Dock for users based on some criteria; like AD groups for example (you'd have to modify the source based on your criteria).
Features
- Builds a Dock based on pre-defined defaults
- Logs to ~/Library/Logs/DockBuilder.log (by default)
- Does not start until the Dock.app is loaded upon login
- Only builds a Dock for user's who's Dock is younger than 300 seconds (to minimize re-building a pre-existing user's Dock after the installation of DockBuilder)
- Option to hide the Dock and display a message to the user while the Dock is being built
I created a version of this for my workplace, but this includes a lot more functionality and leverages a plist to store preferences for easy manipulation in the future.
Use it, or don't. Create an issue if you have any or submit a PR.
Posted on 05-15-2019 09:31 AM
Nice Ryan!
Posted on 05-15-2019 11:39 AM
Thanks for creating this, Ryan! Very simple to set up – this may be something I can use in labs to set default docks. I have it running successfully on one of my VM systems for further testing.
Posted on 05-15-2019 12:43 PM
Thanks @ryan.ball Always appreciate someone smarter making my life easier (and even fun at times!).
Will give it a run.
Posted on 05-15-2019 04:16 PM
This is awesome. I've been playing with it and it works really well! Thanks for building it and sharing with us!
Posted on 05-15-2019 05:37 PM
Thanks. If anybody has a use case for different dock per user using some criteria, let me know.
I’ll probably also work in the addition of Dock items even after DockBuilder has ran for a particular user, like if an organization needs a new app added. Also the removal of a Dock item after DockBuilder might have run for a user. This would eliminate the need for one-off solutions for maintenance purposes.
Posted on 05-16-2019 01:10 PM
It would be kind of nice to be able to give a different dock to our hidden admin account.
Posted on 05-16-2019 01:56 PM
I'll work on a way to ignore users from the postinstall check that creates breadcrumbs for users that already existed, so that we build the Dock for the user that already existed (if it did). Also, I can look at setting up a different set of items to apply to another user named "admin" for example.
Posted on 05-16-2019 06:27 PM
@ryan.ball Dude, sweet!
Not only is this great work, but you open sourced it for the whole community! You're a saint.
I will commence clicking all the "Likes" for your posts in this discussion. I don't really know what that does, is it just fake internet points or do they go toward something like a free pizza...
Anyway, how do you handle PPPC for this? I mean since there's a launch agent, the app is run by the $USER. I haven't figured out a good way whitelist scripts and apps that are run under those conditions.
Last thing, love your avatar!
Posted on 05-17-2019 06:11 AM
@nwagner Thanks! I've used this on all flavors of Mojave, and it does not require a PPPC profile from what I can tell.
Posted on 05-17-2019 09:07 AM
@isaacnelson This has been added. Look at the comments around line 52 of build.sh, then lines 108 in dockbuilder.sh.
Posted on 05-17-2019 12:54 PM
Awesome! I'm at an offsite today but I should be able to play with it a bit on Monday.
Posted on 05-17-2019 02:04 PM
For me?! You're too kind.
Posted on 05-19-2019 06:46 PM
This is a prime example of open source driving and helping more open source. This is the type of stuff the community and jamf should embrace. Good work.
Posted on 10-10-2019 05:26 PM
Hello, does anyone have problem with dockbuilder on 10.15 Catalina? Apple's app icon are missing from the dock (displayed as question mark)
Posted on 10-10-2019 07:18 PM
ah just realised some items in /Applications/ is now at /System/Applications/
Posted on 03-09-2020 01:12 PM
Jamf needs to buy this and add it into their software. The current way to do this in Jamf is a crapshoot most of the time.
Posted on 03-09-2020 01:25 PM
I'm just starting on building next school years, lab setups and this was one area causing me fits. This saves me many hours of trying to get it working or resorting to using cloned base images. So thank you very much!
Posted on 10-05-2020 01:11 PM
Confirmed working with Catalina 10.5.7. Thanks!
Posted on 10-08-2020 09:20 AM
Thanks. If anybody has a use case for different dock per user using some criteria, let me know.
@ryan.ball Would be good to have the ability to have different dock setups for desktops & laptops
Posted on 10-08-2020 10:02 AM
@Tangentism This could probably be accomplished without too much trouble by building two packages and deploying them to different smart groups in Jamf Pro.
Posted on 10-08-2020 10:10 AM
Additionally, I've pondered making a swift version of this which would use a configuration profile to set the dock up. Then just changing the profile for machines would allow for easy customizations.
Posted on 10-08-2020 02:14 PM
@ryan.ball That would be awesome to have a way to set docks through configuration profiles. That would definitely make life easier!
Posted on 10-08-2020 05:29 PM
@ryan.ball Does your DockBuilder allow people to alter their Dock once it has been set by Dock Builder? I like to give my faculty a clean Dock with just the barest minimum that they all would be using, yet allow them to add items to their dock if they want.
Posted on 10-09-2020 04:02 AM
@kwoodard it sets the Dock once with the items you specify and after that it will not modify the Dock again so users can make any changes they’d like.
Posted on 06-08-2021 02:08 AM
Hey @ryan.ball
Looks like Monterey is complaining that "DockBuilder" needs to be updated. This app will not work with future versions of macOS… blah blah.
Is there something you might be able to fix or is it Platypus that is not creating a Universal .app?
Posted on 08-03-2021 02:57 PM
@remus This needs to be updated to a signed Swift app, but I don't use this any longer and don't know if I want to update it. Alternatively you can build the project and then sign/notarize it yourself which might be a quick work-around.
Posted on 11-05-2021 09:00 AM
It's looking like a rebuild, sign and notarization of DockBuilder.app is working for me. FYI
Posted on 11-10-2021 10:26 AM
Well, I may have spoken too soon. Subsequent build attempts after my first couple seem to be showing the alert again. Not sure what to do at this point.
Posted on 04-26-2022 10:22 AM
For anyone looking to build a custom dock in Monterey, I piggybacked off @ryan_ball 's awesome work, rewrote a bunch of stuff and created a new post here:
https://community.jamf.com/t5/jamf-pro/build-a-custom-macos-dock/m-p/264565#M243152