Skip to content

Instantly share code, notes, and snippets.

@chaosbunker
Created May 19, 2018 20:56
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save chaosbunker/041b33f1a7826931dee238cf27d4bafb to your computer and use it in GitHub Desktop.
Save chaosbunker/041b33f1a7826931dee238cf27d4bafb to your computer and use it in GitHub Desktop.
Completely remove munkitools
#!/usr/bin/env bash
sudo launchctl unload /Library/LaunchDaemons/com.googlecode.munki.*
sudo rm -rf "/Applications/Utilities/Managed Software Update.app"
sudo rm -rf "/Applications/Managed Software Center.app"
sudo rm -f /Library/LaunchDaemons/com.googlecode.munki.*
sudo rm -f /Library/LaunchAgents/com.googlecode.munki.*
sudo rm -rf "/Library/Managed Installs"
sudo rm -rf "/Library/Managed Preferences"
sudo rm -f /Library/Preferences/ManagedInstalls.plist
sudo rm -rf /usr/local/munki
sudo rm /etc/paths.d/munki
sudo pkgutil --forget com.googlecode.munki.admin
sudo pkgutil --forget com.googlecode.munki.app
sudo pkgutil --forget com.googlecode.munki.core
sudo pkgutil --forget com.googlecode.munki.launchd
sudo pkgutil --forget com.googlecode.munki.app_usage
@homebysix
Copy link

homebysix commented Apr 13, 2024

Don't recommend removing /Library/Managed Preferences, as it isn't specific to Munki.

This uninstall script from the Munki project should be up to date, and includes the Python package receipt removal: https://github.com/munki/munki/blob/8edfc6a825234b4c26e721de201dd43ed8b9e26b/code/tools/uninstall_munki.sh#L4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment