In Munki, NoPkg is a type of package without a payload. It essentially allows users to leverage Munki to execute scripts and detect changes in the installed state. While SimpleMDM has long provided a robust self-hosted Munki integration, we recently added support for the NoPkg option. This dramatically expands SimpleMDM’s script execution capabilities. We’ll tell you the basics of what NoPkg is and how you can use it.
What is a NoPkg?
A NoPkg is a Munki PkgInfo item that uses metadata and scripts to perform actions. As the name suggests, NoPkg doesn’t contain a package, meaning it lacks a PKG or DMG payload. This allows NoPkg to run scripts, perform recurring tasks, manage settings, and automatically check for changes in the installed state without installing files on the client. You can also use NoPkgs to provide self-service scripts via the SimpleMDM Managed Software Center. No need to search for an executable, download it, and rename it!
What's the difference between a payload-free PKG and a NoPkg?
Both payload-free PKGs and NoPkgs are items without payloads. Like any PKG, a payload-free PKG can be installed and uninstalled as a package, and it leaves a receipt to show it ran. You can also use payload-free PKGs without Munki. That means it’s the go-to option in non-Munki environments or if you plan to only run the script once.
On the other hand, NoPkg does not need to be installed or uninstalled as a package. Munki manages it directly through the scripts and other tools included in the item. The main benefit of a NoPkg is that it runs every time Munki runs on the client, checking and rechecking whether the installed state changed and then rerunning the script as necessary.
Why is NoPkg important for SimpleMDM’s hosted Munki integration?
Supporting NoPkg enhances SimpleMDM’s power and flexibility. Since NoPkg allows you to use Munki as a general script execution tool, supporting the NoPkg installer type in combination significantly expands SimpleMDM’s script execution capabilities.
With SimpleMDM, you can use a NoPkg in two ways:
Create your own and upload it
Copy an existing NoPkg and paste it into the text editor
Check out the official Munki documentation for more information on how to create a NoPkg. Once you have a NoPkg ready to go, just use an assignment group to deploy it to your target machines.
NoPkg use cases
NoPkg is quite flexible, so you can utilize it for a wide variety of tasks. Here are just a few examples:
Create symbolic links
Set app or system preferences without needing to reinstall the software
Ultimately, you can use Munki NoPkg pretty much whenever you want to manage settings or configurations without distributing a software payload.
When should I still use a package? When should I use NoPkg?
We recommend continuing to use a package if you’re installing files or resources and a package is available for your OS. A NoPkg is the go-to method for any actions that do not require file installation, like changing configurations, setting preferences, and creating symbolic links.