Home > AutoPkg, Mac administration > Using AutoPkg recipes with alternate software downloads

Using AutoPkg recipes with alternate software downloads

An issue that crops up occasionally for AutoPkg is that a vendor will release a new version of their software but be slow to update the download location which an AutoPkg recipe is looking at. Alternatively, there may be instances where a software vendor releases two versions of their software and AutoPkg only picks up one of them. A good example of this is Oracle’s Java 8, where the past few releases of Java 8 have actually had two versions of Java 8 released simultaneously.

Fortunately, if you can manually download the needed software, there is a way to leverage AutoPkg to generate the needed installer without needing to change your AutoPkg recipe. See below the jump for details.

To use Oracle’s release behavior as an example, Oracle currently has Java 8 Update 73 and Java 8 Update 74 available. What’s the difference between Update 73 and Update 74? Update 73 is a Critical Patch Update (CPU), which contains both fixes to security vulnerabilities and critical bug fixes. Update 74 is a Patch Set Update (PSU), which means it contains all the fixes in the corresponding CPU, plus additional fixes to non-critical problems. So the short version is that Update 73 has “critical bug fixes” and Update 74 has “Update 73’s bug fixes, plus more bug fixes.”

For those interested in more details on the differences between CPU and PSU updates, please see the link below:


AutoPkg’s Java 8 .download recipes will download Java 8 Update 73, but it will not detect or download Java 8 Update 74. To address this issue, the disk image for Java 8 Update 74 can be manually downloaded and then be used as a source by AutoPkg recipes. This option is available via the -p or –pkg option for AutoPkg’s run function.

Screen Shot 2015 01 26 at 7 36 26 AM

Specifying the -p option tells AutoPkg not to download the software as it normally would, but instead use the referenced installer package or disk image in place of what would normally be downloaded.

For those that would need to have Java 8 Update 74, you would use the -p or –pkg option for AutoPkg’s run function and reference a Java 8 Update 74 disk image when running your recipe. In this example, I’m using a OracleJava8.pkg recipe:

autopkg run OracleJava8.pkg -p /path/to/downloaded_Java_8_disk_image.dmg

Screen Shot 2016 03 15 at 3 03 32 PM

Instead of AutoPkg downloading Java 8 Update 73 from Oracle’s website and creating a Java 8 Update 73 installer, the disk image containing the Java 8 Update 74 installer is referenced by the OracleJava8.pkg recipe and a Java 8 Update 74 installer package is generated.

Screen Shot 2016 03 15 at 3 06 02 PM

  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: