Munki and File System Permissions

The script assumes that if the repo is accessed from a network share that the share has been mapped as appropriate before it's run.

Munki Import

Auto Munki Importer uses munkiimport to import the packages.

Please ensure that munkiimport --configure has been run and has the correct configuration for the "Path to munki repo" and "pkginfo extension" options for the user that will be running the script.


In addition to writing to the Munki repo, the script needs to also write to the data plists, and log files. While these files can be anywhere, the default locations are:-

  • /Library/​Application Support/​autoMunkiImporter
  • /Library/​Logs/​autoMunkiImporter

Auto Munki Importer Global Config

The default settings plist contains configuration for the script. It has a series of required keys, some of which may be overwritten by individual data plists.

A default settings plist is installed to /Library/​Application Support/​autoMunkiImporter/​_DefaultConfig.plist. You can however override this using the --settings /path/to/settings.plist command line paramater.

Please take the time to review the settings and change them as appropriate for your environment. If the email settings aren't changed, the script will exit during its initial checks, even if emailing reports is disabled.

Required Keys





Location of data plist(s) (Default: /Library/​Application Support/​autoMunkiImporter/).


Whether email reports should be sent (Default: True).


From email address to use for sending email (Default: Needed regardless of whether emailReports is true or false.


Whether to add and commit new pkginfos with git (Default: False).


Whether to pull and push changes to and from a remote git repo (Default: False).


Path to the log file to use (Default: /Library/​Logs/​autoMunkiImporter/​autoMunkiImporter.log).


Size in MBs that log files can grow to until they are rolled (Default: 1MB).


Whether makecatalogs should be run at the end of each import (Default: True).


Maximum number of logs files to keep (Default: 5).


SMTP server to use for sending email (Default: Needed regardless of whether emailReports is true or false.


Path to status plist, which gives a summary of all applications being monitored (Default: /Library/​Logs/​autoMunkiImporter/​autoMunkiImporterStatus.plist).


Prefix to add to email subject lines (Default: [Auto Munki Import]). Needed regardless of whether emailReports is true or false.


To email address to use for receiving email (Default: Needed regardless of whether emailReports is true or false.


The User Agent string to use when attempting to download applications (Default: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/536.26.14 (KHTML, like Gecko) Version/6.0.1 Safari/536.26.14). I recommendation you use Safari's User Agent for your primary OS (the default is for Lion).

Once you have installed the dependencies and configured the settings plist, Auto Munki Importer should have everything it needs to run. You can verify this by running --test. You should get "All tests passed..." if everything has been configured correctly.

Example Data Plists

The installer package contains the following example data plists that you can use as a starting point for automating your packaging. They are installed into /Library/​Application Support/​autoMunkiImporter.

  • Adobe Flash Player
  • Adobe Reader
  • Firefox (Extended Support Release)
  • Firefox (Public Release)
  • Flip4Mac WMV Quicktime Components
  • Google Chrome
  • Silverlight
  • Skype
  • VLC

In addition an empty _template.plist is included as a starting point for your own applications. It has all of the required and optional keys. Unused keys can be left blank.

If you plan on using this directory to host your data plists, you should review each of the examples and ensure they match your pkginfo names and locations of existing items and that they have the appropriate settings.

Launch Daemon

To fully automate importing packages into Munki, the script should be set to run as a Launch Daemon. An example plist appears below that uses the default install locations and will run at 5am each day. If you modify where the data plists, or the location of the script are you will need to make the appropriate changes.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">
		<string>/Library/Application Support/autoMunkiImporter</string>

You should set the UserName to match a user that has munkiimport configured, and has appropriate permissions as outlined above.

Save the plist to /Library/​LaunchDaemons/​com.github.neographophobic.autoMunkiImporter.plist, and then run sudo chown root:wheel /Library/​LaunchDaemons/​com.github.neographophobic.autoMunkiImporter.plist and sudo chmod 644 /Library/​LaunchDaemons/​com.github.neographophobic.autoMunkiImporter.plist.

You should then load it, so that launchd is aware of it and will run it at 5am tomorrow. To load the plist use sudo launchctl load /Library/​LaunchDaemons/​com.github.neographophobic.autoMunkiImporter.plist.