A cached installer that is used by a Install Policy and also allow it to be used for a Self Serve policy

kirbybj
New Contributor III

I am caching a macOS installer. I want to have an Install Policy and also a Self Serve Policy. So the User can either upgrade when they get the Installer Prompt or they can go to our App Store and select it from there when they are ready.
I have created a Cache policy, Install Policy and a Self Serve Policy.
The Computer falls in to the smart group to cache the bits, once the bits are cached the Install policy gives the user a popup if they want to Defer or continue with the Upgrade. At this time the Self Serve policy populate our App Store for the user to have the option of Upgrading. The problem comes in if the User defers on the install policy it removes the bits and the Self Serve option is removed from the App Store. Is there a way for the User to defer the Install Policy and the bits remain on the machine for the App store option when the user is ready to Upgrade?

6 REPLIES 6

sdagley
Esteemed Contributor II

@kirbybj Can you clarify how you have your current policies set up? If I were taking the approach I think you're describing this is how I'd set up the cache and install policies if I were trying to upgrade to macOS Catalina:

Caching Policy - Scoped to all computers not already running macOS Catalina
Trigger Recurring Check-in and Execution Frequency Ongoing
Packages payload with Install macOS Catalina.pkg with the Action set to Cache
Maintenance payload to Update Inventory

A Smart Group named macOS Installer is Cached that uses the criteria Cached Packages has Install macOS Catalina.pkg

Install Policy - Scoped to Macs in the macOS Installer is Cached Smart Group
Packages Payload with Install macOS Catalina.pkg with the Action set to Install Cached
Trigger Recurring Check-in and Execution Frequency Once Every Day
Script Payload with Priority set to After to execute your install script

Self Service Policy - Scoped to Macs in the macOS Installer is Cached Smart Group
Packages Payload with Install macOS Catalina.pkg with the Action set to Install Cached
No Trigger and Execution Frequency Once Per Computer
Make available in Self Service, with appropriate description
Script Payload with Priority set to After to execute your install script

What I'd also strongly recommend is that you take a look at using macOSUpgrade as your installer script. There's several nuances to running a macOS installer, and this script addresses pretty much all of them.

kirbybj
New Contributor III

Thanks for the Reply and detail. I see a few things I did wrong and will adjust to see if it helps. I need to read about one of your steps because I am not sure what it is. I am new to Jamf and feeling my way around.
The step is "Script Payload with Priority set to After to execute your install script"

But this is what I had setup before reading your post.

Cache Policy - named Catalina Upgrade (Cache) - Scoped to Catalina Upgrade (Not Installed)
Trigger - Recurring Check-in
Packages - Set to Cache - CatalinaUpgrade.pkg Maintenance - Update Inventory

SmartGroup - named Catalina Upgrade (Not Installed) - Criteria - Cached Packages has CatalinaUpgrade.pkg and a few other items like check for disk space.

Install Policy - named Catalina Upgrade (Installed) - Scoped to Catalina Upgrade (Not Installed)Trigger Recurring Check-in - Execution Frequency - Once every day
Packages - Install Cached - CatalinaUpgrade.pkg
Maintenance - Update Inventory

Self Serve Policy - Scoped to SmartGroup - named Catalina Upgrade (Not Installed)
Packages - Set to Install Cached - CatalinaUpgrade.pkg
Trigger - Recurring. Check-in and Execution Frequency - Ongoing. (I see my mistake here)
Maintenance - Update Inventory

sdagley
Esteemed Contributor II

@kirbybj What exactly is your CatalinaUpgrade.pkg? If it's the Install macOS Catalina app wrapped in a .pkg then installing it isn't actually going to launch it. Unless you're expecting your users to manually run the app you will need a script to start the upgrade process, and that's where macOSUpgrade comes in.

kirbybj
New Contributor III

@sdagley
Thanks for the reply. I do have a script that is launching the install.
I am using PostFlight to call Start_macOS_Upgrade.sh which installs the Install macOS Catalina app.
It works as planned, my issue is when I tried to introduce a self serve policy.
If I defer the install policy because the User may want to do this later it removes the cached bits and then the self serve item in our App Store.
I wanted the User to be able to defer and later go back to our App Store and use the Install there to Upgrade. is there a way to keep the cached bits there until either the Install policy is selected to continue or the User uses the App Store to launch the install?
I must be missing something I just cannot put my finger on it.

sdagley
Esteemed Contributor II

@kirbybj A few things:

Having a postflight script is not how you'd want to start the macOS install process as it's going to prevent the policy from checking in with Jamf Pro on completion since the Mac will restart to complete the install.

Remove the postflight (and/or postinstall as that's the more common type of script to use if you want to run something after install) from your .pkg and just have it drop Install macOS Catalina.app into /Applications

Use the macOSUpgrade script to actually run the upgrade as it will allow the policy calling it to complete before the install starts

kirbybj
New Contributor III

@sdagley I will definitely followup on your suggestions. Like I said I am pretty new to this. Thank you.