Setting Package Priorities from within a Policy

Marababol
New Contributor

I created a policy to install RealVNC Server which I downloaded and decompiled from their website into .pkg format which I named VNC-Server-Install.pkg

I then created a .pkg file that contains the license activation and customized settings for the application which I named VNC-ServerLicense.pkg

I am able to create a policy and place these 2 .pkg files into the Packages option.

What I would like to happen is that the VNC-ServerLicense.pkg gets executed/installed first before the VNC-Server-Install.pkg. In other words the license should install first.

However the .pkg's are displayed alphabetically in the Packages list. Is there a way for me to set the order of precedence for the .pkg files so that the licensing comes first? I would like to just have one policy that contains both so that the installation and licensing is done in one installation.

If for example, I rename the Display Name of the .pkg files and add a prefix like 1- and 2- to arrange them in order in the list, will this address my concern in having the 1- execute first before the 2- labeled .pkg file?

Thanks.

3 REPLIES 3

davidhiggs
Contributor III

You can set priorities for packages from the Casper Admin app, or from the JSS in Computer Management > Packages.

Some people will organise a priority number system that works in their environment. eg. Set low numbers for pre-installation packages, mid numbers for normal apps, high numbers for updates, higher numbers for licence packages. etc.

Once you've set them, they automatically appear in the correct order in your policy, you dont need to manually do this.

hope that helps!

Marababol
New Contributor

Just wondering if both packages have the same priority value but say I rename the files so that one displays as 1-package.pkg and the other as 2-package.pkg. This will rearrange the way they appear in the policy showing the 1- first before the 2-. Will this also work? Meaning will the script execute the .pkg that has the 1- before the one that has the 2-?

Just wondering.

davidhiggs
Contributor III

that method will also work, after priorities it will follow normal file system ordering.

maybe duplicate the policy and change the scope to a test machine, no harm in a bit of trial and error!