Autopkgr + JSSImporter: Smart groups get updated regardless of app update

khenley
New Contributor II

Hello, I'm using Autopkgr with the JSSImporter integration. Sometime in the past the JSSImporter changed it's behavior. It used to change a policy's smart group's definition ONLY if there was an update. No update, meant no changes are made on the JSS. This way I would simply delete the "and member of Testing" from the smart group's criteria once I was I done testing. Now however, every time autopkgr runs recipes, and regardless if there is an update, it touches all the "Appname-smart" smart-groups and adds the "and member of Testing" back to them. I prefer the "don't touch it unless there is an update" method.

Has anyone else noticed, or been annoyed by this? Am I missing something? I tried a fresh install and results are the same. This "update it always" seems to be the norm now. I haven't dug into the source code of the JSS Importer yet.

1 REPLY 1

elliotjordan
Contributor III

Hi @khenley,

There hasn't been a JSSImporter update since September 2015, so it's unlikely that the behavior changed on JSSImporter's side. But I wouldn't manually modify objects (policies, groups, or extension attributes) created by JSSImporter, because it's likely your modifications will be overwritten.

The method I use and recommend is to create two sets of overrides:

  • AppName-testing.jss.recipe — Creates a Self Service policy that allows people in the Testing group to install AppName if they don't have the latest version. This is the default jss-recipes behavior, so this override doesn't actually override anything; I just create it for sanity of nomenclature.
  • AppName-selfservice.jss.recipe — Creates a Self Service policy that allows anybody to install AppName if they don't have the latest version. For this to work, a PolicyTemplate-selfservice.xml file must also exist in the RecipeOverrides folder, and this file will be identical to the default policy template except for the fact that you'll set the scope to <all_computers>true</all_computers>.

I write a step by step guide for this method in Section 6c of Auto Update Magic. You can see an example of the PolicyTemplate-selfservice.xml file here.

Hope that helps a little!